mirror of
https://github.com/discourse/discourse.git
synced 2024-11-30 12:43:54 -06:00
FIX: PageTracker was not sending the proper page title through at all
times.
This commit is contained in:
parent
2d9187cd9d
commit
a0e92ef57a
@ -19,7 +19,13 @@ Discourse.PageTracker = Ember.Object.extend(Ember.Evented, {
|
||||
|
||||
router.on('didTransition', function() {
|
||||
this.send('refreshTitle');
|
||||
self.trigger('change', this.get('url'), Discourse.get('_docTitle'));
|
||||
var url = this.get('url');
|
||||
|
||||
// Refreshing the title is debounced, so we need to trigger this in the
|
||||
// next runloop to have the correct title.
|
||||
Em.run.next(function() {
|
||||
self.trigger('change', url, Discourse.get('_docTitle'));
|
||||
});
|
||||
});
|
||||
this.set('started', true);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user