Revisions: Immediately do a disabled button check on `ready()`.

Solves the issue of Prev/Next buttons not being disabled on initial load, when routing to an extremity.

See #24425.

git-svn-id: http://core.svn.wordpress.org/trunk@24661 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Mark Jaquith 2013-07-11 18:43:18 +00:00
parent 2940a03ae5
commit 0fabcaaa0a
1 changed files with 2 additions and 1 deletions

View File

@ -664,10 +664,11 @@ window.wp = window.wp || {};
initialize: function() { initialize: function() {
this.$el.html( this.template() ); this.$el.html( this.template() );
this.listenTo( this.model, 'update:revisions', this.disabledButtonCheck );
}, },
ready: function() { ready: function() {
this.listenTo( this.model, 'update:revisions', this.disabledButtonCheck ); this.disabledButtonCheck();
}, },
// Go to a specific modelindex, taking into account RTL mode. // Go to a specific modelindex, taking into account RTL mode.