Merge remote-tracking branch 'refs/remotes/origin/master' into develop

This commit is contained in:
Barış Soner Uşaklı
2018-02-03 13:21:42 -05:00

View File

@@ -117,10 +117,9 @@ define('notifications', ['sounds', 'translator', 'components', 'navigator', 'ben
function scrollToPostIndexIfOnPage(notifEl) {
// Scroll to index if already in topic (gh#5873)
var pid = notifEl.attr('data-pid');
var tid = notifEl.attr('data-tid');
var path = notifEl.attr('data-path');
var postEl = components.get('post', 'pid', pid);
if (path.startsWith(config.relative_path + '/post/') && pid && postEl.length && ajaxify.data.template.topic && parseInt(ajaxify.data.tid, 10) === parseInt(tid, 10)) {
if (path.startsWith(config.relative_path + '/post/') && pid && postEl.length && ajaxify.data.template.topic) {
navigator.scrollToIndex(postEl.attr('data-index'), true);
return true;
}