mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-09-25 03:08:42 +00:00
ve.init.mw.ArticleTarget: Fix error handling in #prepareCacheKey
If the paction=serializeforcache request fails, we were erroneously converting it to a successful result with no value, which later causes an exception, because since381b58585c
other code expects the result to an an object. The bug was introduced in 2015 in07001001be
, but until that recent change it would only cause a 'badcachekey' error, which was handled correctly later. Change-Id: Ie1ffc8c3e616a7d296f2186fb17eaf039971a44f
This commit is contained in:
parent
36bde9d1c6
commit
a53c02f2c4
|
@ -1323,6 +1323,7 @@ ve.init.mw.ArticleTarget.prototype.prepareCacheKey = function ( doc ) {
|
|||
},
|
||||
function () {
|
||||
target.events.track( 'performance.system.serializeforcache.fail', { duration: ve.now() - start } );
|
||||
return ve.createDeferred().reject();
|
||||
}
|
||||
);
|
||||
} )
|
||||
|
|
Loading…
Reference in a new issue