mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-10 16:05:49 +01:00
closes #3759
This commit is contained in:
@@ -146,7 +146,7 @@ define('forum/topic', [
|
|||||||
if (components.get('post/anchor', postIndex).length) {
|
if (components.get('post/anchor', postIndex).length) {
|
||||||
return navigator.scrollToPostIndex(postIndex, true);
|
return navigator.scrollToPostIndex(postIndex, true);
|
||||||
}
|
}
|
||||||
} else if (bookmark && (!config.usePagination || (config.usePagination && ajaxify.data.pagination.currentPage === 1)) && ajaxify.data.postcount > 10) {
|
} else if (bookmark && (!config.usePagination || (config.usePagination && ajaxify.data.pagination.currentPage === 1)) && ajaxify.data.postcount > 5) {
|
||||||
app.alert({
|
app.alert({
|
||||||
alert_id: 'bookmark',
|
alert_id: 'bookmark',
|
||||||
message: '[[topic:bookmark_instructions]]',
|
message: '[[topic:bookmark_instructions]]',
|
||||||
@@ -277,7 +277,7 @@ define('forum/topic', [
|
|||||||
var bookmarkKey = 'topic:' + ajaxify.data.tid + ':bookmark';
|
var bookmarkKey = 'topic:' + ajaxify.data.tid + ':bookmark';
|
||||||
var currentBookmark = ajaxify.data.bookmark || localStorage.getItem(bookmarkKey);
|
var currentBookmark = ajaxify.data.bookmark || localStorage.getItem(bookmarkKey);
|
||||||
|
|
||||||
if (!currentBookmark || parseInt(index, 10) > parseInt(currentBookmark, 10)) {
|
if (ajaxify.data.postCount > 5 && (!currentBookmark || parseInt(index, 10) > parseInt(currentBookmark, 10))) {
|
||||||
if (app.user.uid) {
|
if (app.user.uid) {
|
||||||
socket.emit('topics.bookmark', {
|
socket.emit('topics.bookmark', {
|
||||||
'tid': ajaxify.data.tid,
|
'tid': ajaxify.data.tid,
|
||||||
|
|||||||
Reference in New Issue
Block a user