mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 13:33:24 +00:00
hashchange: Add warning if pushState is not available.
This commit is contained in:
@@ -303,7 +303,10 @@ run_test('save_narrow', () => {
|
||||
{operator: 'is', operand: 'private'},
|
||||
];
|
||||
|
||||
blueslip.set_test_data('warn', 'browser does not support pushState');
|
||||
hashchange.save_narrow(operators);
|
||||
blueslip.clear_test_data();
|
||||
|
||||
helper.assert_events([
|
||||
'message_viewport.stop_auto_scrolling',
|
||||
'favicon.reset',
|
||||
|
||||
@@ -31,6 +31,7 @@ function set_hash(hash) {
|
||||
var url = get_full_url(hash);
|
||||
history.pushState(null, null, url);
|
||||
} else {
|
||||
blueslip.warn('browser does not support pushState');
|
||||
window.location.hash = hash;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user