Opened 18 years ago
Closed 18 years ago
#4737 closed defect (bug) (fixed)
Attempting to edit post/page that doesn't exist doesn't generate an error message
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | 2.3 | Priority: | lowest |
Severity: | minor | Version: | 2.3 |
Component: | Administration | Keywords: | has-patch commit |
Focuses: | Cc: |
Description
post.php?action=edit&post=X
(and it's page counterpart) doesn't check the entered ID to see if it exists. If a user edits the URL (or more likely bookmarks the URL for later editing) but the post ID doesn't exist (say it's deleted after bookmark), no pretty error message is displayed.
Instead, a blank edit form is displayed (such as the Write post screen) and on the edit post page, following error is displayed:
Warning: Attempt to assign property of non-object in [...]/wp-admin/edit-form-advanced.php on line 49
(for obvious reasons)
A simple fix is attached that should do the job.
Attachments (3)
Change History (6)
Note: See
TracTickets for help on using
tickets.
Better L10n support?