mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-15 02:23:58 +00:00
ApiResponseCache: Add a check for data.query before accessing redirects
Follow-up: If4f8c9b6719c123b31d852eb71f06a79cc0f7917 Change-Id: I5f1814f341ce401fcb3926487a2cea276698bca0
This commit is contained in:
parent
a93d1e6102
commit
b049a82e8d
|
@ -164,7 +164,7 @@ ve.init.mw.ApiResponseCache.prototype.processQueue = function () {
|
|||
pages = ( data.query && data.query.pages ) || data.pages,
|
||||
processed = {};
|
||||
|
||||
redirects = data.query.redirects || [];
|
||||
redirects = ( data.query && data.query.redirects ) || [];
|
||||
if ( pages ) {
|
||||
for ( pageid in pages ) {
|
||||
page = pages[ pageid ];
|
||||
|
|
Loading…
Reference in a new issue