hamstar / Wikimate

A MediaWiki API wrapper for PHP based wikibots that [shouldn't] be confusing to use
MIT License
58 stars 24 forks source link

Clarify error response for edits denied by a CAPTCHA (fixes #144) #145

Closed Xymph closed 2 years ago

Xymph commented 2 years ago

If the ConfirmEdit extension is enabled with a Captcha module, this can block five types of activity. The latter two (createaccount & badlogin) are not relevant to Wikimate, the former three (edit, create & addurl) can occur via Wikimate::edit() in WikiPage::setText().

This PR sets an error message "Edit denied by CAPTCHA" for this situation, instead of the generic "Unexpected edit response". If the message isn't clear enough, please suggest a better wording.

Xymph commented 2 years ago

@Dusan-Krehel, please try this change and let me know if this what you expect.

Dusan-Krehel commented 2 years ago

@Xymph I looked at the commit code (without real tests). My request is granted.