mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: hooks is sometimes undefined
This commit is contained in:
@@ -593,11 +593,14 @@ app.cacheBuster = null;
|
||||
});
|
||||
|
||||
let ajaxified = false;
|
||||
hooks.on('action:ajaxify.end', function () {
|
||||
if (!ajaxify.isCold()) {
|
||||
ajaxified = true;
|
||||
}
|
||||
require(['hooks'], function (hooks) {
|
||||
hooks.on('action:ajaxify.end', function () {
|
||||
if (!ajaxify.isCold()) {
|
||||
ajaxified = true;
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
inputEl.on('focus', function () {
|
||||
mousedownOnResults = false;
|
||||
const query = inputEl.val();
|
||||
|
||||
Reference in New Issue
Block a user