mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-09-25 19:26:46 +00:00
Convert the last two uses of $.toJSON to ve.getHash
Change-Id: Iff033590a6033a8de88dc571481442a819146c90
This commit is contained in:
parent
f26ae1662b
commit
2d36ce9465
|
@ -231,7 +231,7 @@ ve.dm.DocumentSynchronizer.prototype.queueEvent = function ( node, event ) {
|
||||||
// Check if this is already queued
|
// Check if this is already queued
|
||||||
var
|
var
|
||||||
args = Array.prototype.slice.call( arguments, 1 ),
|
args = Array.prototype.slice.call( arguments, 1 ),
|
||||||
hash = $.toJSON( args );
|
hash = ve.getHash( args );
|
||||||
|
|
||||||
if ( !node.queuedEventHashes ) {
|
if ( !node.queuedEventHashes ) {
|
||||||
node.queuedEventHashes = {};
|
node.queuedEventHashes = {};
|
||||||
|
|
|
@ -118,7 +118,7 @@ ve.dm.TransactionProcessor.processors.annotate = function ( op ) {
|
||||||
throw new Error( 'Invalid annotation method ' + op.method );
|
throw new Error( 'Invalid annotation method ' + op.method );
|
||||||
}
|
}
|
||||||
|
|
||||||
hash = $.toJSON( op.annotation );
|
hash = ve.getHash( op.annotation );
|
||||||
if ( op.bias === 'start' ) {
|
if ( op.bias === 'start' ) {
|
||||||
target[hash] = op.annotation;
|
target[hash] = op.annotation;
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue