1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-01-17 22:28:46 +01:00

[ticket/12843] Fix Mark forums read browser console error

When you click on "Mark forums read" in the browser console error occurs
ReferenceError: assignment to undeclared variable phpbbAlertTimer
ajax.js (line13)

PHPBB3-12843
This commit is contained in:
Sumanai 2014-07-12 22:03:58 +04:00 committed by Joas Schilling
parent 48679eeff8
commit ab8400a616
2 changed files with 12 additions and 11 deletions

View File

@ -47,6 +47,18 @@ phpbb.clearLoadingTimeout = function() {
}
};
/**
* Close popup alert after a specified delay
*
* @param int Delay in ms until darkenwrapper's click event is triggered
*/
phpbb.closeDarkenWrapper = function(delay) {
phpbbAlertTimer = setTimeout(function() {
$('#darkenwrapper').trigger('click');
}, delay);
};
/**
* Display a simple alert similar to JSs native alert().
*

View File

@ -2,17 +2,6 @@
"use strict";
/**
* Close popup alert after a specified delay
*
* @param int Delay in ms until darkenwrapper's click event is triggered
*/
phpbb.closeDarkenWrapper = function(delay) {
phpbbAlertTimer = setTimeout(function() {
$('#darkenwrapper').trigger('click');
}, delay);
};
// This callback will mark all forum icons read
phpbb.addAjaxCallback('mark_forums_read', function(res) {
var readTitle = res.NO_UNREAD_POSTS;