mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-08-09 10:22:51 +03:00
Merge branch 'conflict_warnings' of https://github.com/MatthieuParis/BookStack into MatthieuParis-conflict_warnings
This commit is contained in:
@@ -43,6 +43,16 @@ class PageEditActivity
|
||||
return trans('entities.pages_draft_edit_active.message', ['start' => $userMessage, 'time' => $timeMessage]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if the page has been updated since the draft has been saved.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function hasPageBeenUpdatedSinceDraftSaved(PageRevision $draft): bool
|
||||
{
|
||||
return $draft->page->updated_at->timestamp >= $draft->updated_at->timestamp;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the message to show when the user will be editing one of their drafts.
|
||||
*
|
||||
|
Reference in New Issue
Block a user