[wp-trac] Re: [WordPress Trac] #8119: Attempts to edit deleted
categories are not properly handled
WordPress Trac
wp-trac at lists.automattic.com
Sun Nov 30 10:07:57 GMT 2008
#8119: Attempts to edit deleted categories are not properly handled
-------------------------------+--------------------------------------------
Reporter: mrmist | Owner: westi
Type: defect | Status: new
Priority: normal | Milestone: 2.8
Component: Taxonomy | Version: 2.7
Severity: normal | Resolution:
Keywords: reporter-feedback |
-------------------------------+--------------------------------------------
Comment (by mrmist):
The above warnings and errors were produced without WP_DEBUG.
With regards to version I reproduced this last night when the svn was up
to 9668 I think. Doesn't look like I noted down the original svn revision
but I guess it's safe to say that this code hasn't ever changed, because
the case to produce it is not that frequently seen.
In case I've not been clear in this note that this is not just about
deleting or editing categories. That works just fine and dandy. This is
about a situation where you have two concurrent users working on the same
category. So, for the sake of reproduction for test purposes it would be
-
1. Log on in one browser as a user, go to categories.php
2. Log on in another browser as a different user, go to categories.php
3. As one of the users, delete a category.
4. As the other user, now attempt to edit the category that was just
deleted.
In normal edit, the edit screen now appears, but it's obviously not
populated because the cat has been deleted. There's no message to indicate
that the category has been deleted, though. (Such as you get if you try to
edit a deleted page/post). Instead you get warnings at the top as I noted
in my previous comment.
5. Fill in the edit category box anyway, and press edit category and you
get the message "Your attempt to edit this category: "" has failed." You
can go back, but you cannot (successfully) progress from the edit category
screen.
I cannot reliably reproduce the error message condition which I originally
referred to.
If you additionally enable wp_debug, you get the following notices on the
edit cat page -
br /><b>Notice</b>: Trying to get property of non-object in
<b>/home/www/htdocs/svn/trunk/wp-admin/edit-category-form.php</b> on line
<b>52</b><br />
For lines 57,63,69 as well.
Then on the Error page -
Notice: Undefined property: WP_Error::$name in /home/www/htdocs/svn/trunk
/wp-includes/category.php on line 201
--
Ticket URL: <http://trac.wordpress.org/ticket/8119#comment:5>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list