Last modified: 2012-12-16 17:43:09 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 11135 - wfAjaxWatch in AjaxFunctions.php doesn't check the return value of $article->doWatch();
wfAjaxWatch in AjaxFunctions.php doesn't check the return value of $article->...
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
1.11.x
All All
: Normal normal with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
http://en.wikipedia.org/w/index.php?a...
:
Depends on:
Blocks: 43175
  Show dependency treegraph
 
Reported: 2007-08-31 12:53 UTC by Paolo Liberatore
Modified: 2012-12-16 17:43 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Paolo Liberatore 2007-08-31 12:53:12 UTC
An example where this is a problem: I have two open tabs or windows; I logout in the first, then go to the second one and click "watch". Instead of "you have to be logged in to watch pages", the answer is that the page has been added to the watchlist, while in fact it isn't.
Comment 1 Voyagerfan5761 / dgw 2007-09-16 08:46:56 UTC
It sounds like this is an issue with checking user authentication or something?
Comment 2 Rob Church 2007-09-16 12:17:50 UTC
(In reply to comment #1)
> It sounds like this is an issue with checking user authentication or something?

No, the issue is with the Ajax watch handler's mishandling of failures in the lower-level code that adds a page to a user's watchlist; the authentication is fine, but the code needs to return an appropriate response code or other XML which the client-side code can use to check for an error condition.

Comment 3 Voyagerfan5761 / dgw 2007-09-16 20:05:50 UTC
That would make this an issue with the response. Would simply adding XML output solve the problem, once a parser was added to the script to look for that output value?

Actually, it looks like the watcher script on the server is only returning the operation as a code letter ("<u#>" for unwatch and "<w#>" for watch) followed by the HTML to display on top of the page. Maybe it should have the message watchnologintext returned with a code of "<n#>" or "<f#>" (for "not modified" or "failed") added to the list of possible responses. The script could look for this and display the message like the others, simply changing the ca-watch/ca-unwatch li back to what it had been. Or the server-side script could return different error codes depending on what operation was attempted.
Comment 4 Aaron Schulz 2008-08-04 03:39:12 UTC
Done in r38527. Would be nice to add a custom message or something.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links