Revisions: Use toggleClass instead of a conditional. See #24425.
git-svn-id: https://develop.svn.wordpress.org/trunk@24601 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
7f8538805b
commit
9e5fb3311f
|
@ -278,10 +278,7 @@ window.wp = window.wp || {};
|
||||||
},
|
},
|
||||||
|
|
||||||
updateCompareTwoMode: function() {
|
updateCompareTwoMode: function() {
|
||||||
if ( this.model.get( 'compareTwoMode' ) )
|
this.$el.toggleClass( 'comparing-two-revisions', this.model.get('compareTwoMode') );
|
||||||
this.$el.addClass( 'comparing-two-revisions' );
|
|
||||||
else
|
|
||||||
this.$el.removeClass( 'comparing-two-revisions' );
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue