ApiQueryRevisionsBase: Cast ctype_digit() param to string
Bug: T396766 Change-Id: I22f65e63269ad985f2442176387f2ca96f7609c5 (cherry picked from commit dddeb4e16fae4bae9cd5183548e6db7b3eff2b07)
This commit is contained in:
parent
59f363f9a1
commit
a18e6ca5e6
1 changed files with 1 additions and 1 deletions
|
|
@ -248,7 +248,7 @@ abstract class ApiQueryRevisionsBase extends ApiQueryGeneratorBase {
|
|||
if ( $params['diffto'] == 'cur' ) {
|
||||
$params['diffto'] = 0;
|
||||
}
|
||||
if ( ( !ctype_digit( $params['diffto'] ) || $params['diffto'] < 0 )
|
||||
if ( ( !ctype_digit( (string)$params['diffto'] ) || $params['diffto'] < 0 )
|
||||
&& $params['diffto'] != 'prev' && $params['diffto'] != 'next'
|
||||
) {
|
||||
$p = $this->getModulePrefix();
|
||||
|
|
|
|||
Loading…
Reference in a new issue