mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/ConfirmEdit
synced 2024-11-23 15:56:50 +00:00
Replace isset() with null check in SimpleCaptcha
Found usage of isset() on expression $this->captchaSolved that appears to be always set. isset() should only be used to suppress errors. Check whether the expression is null instead. See https://www.mediawiki.org/wiki/Manual:Coding_conventions/PHP#isset Change-Id: I5520786060b2aa2fca81acd40924d84e94e8dff2
This commit is contained in:
parent
5c1fc0f2e0
commit
b2ec6b2955
|
@ -985,7 +985,7 @@ class SimpleCaptcha {
|
|||
protected function passCaptcha( $index, $word ) {
|
||||
// Don't check the same CAPTCHA twice in one session,
|
||||
// if the CAPTCHA was already checked - Bug T94276
|
||||
if ( isset( $this->captchaSolved ) ) {
|
||||
if ( $this->captchaSolved !== null ) {
|
||||
return $this->captchaSolved;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue