1
0
mirror of https://git.tt-rss.org/git/tt-rss.git synced 2025-12-13 15:25:59 +00:00

set use strict on JS modules; remove some mostly useless stuff like get_minified_js()

This commit is contained in:
Andrew Dolgov
2018-12-02 18:38:27 +03:00
parent 807ff07454
commit f89924f7a1
17 changed files with 32 additions and 72 deletions

View File

@@ -1,3 +1,5 @@
'use strict'
/* global __, ngettext */
define(["dojo/_base/declare"], function (declare) {
return declare("fox.Article", null, {
_active_article_id: 0,

View File

@@ -1,3 +1,5 @@
'use strict'
/* global __, ngettext */
define(["dojo/_base/declare"], function (declare) {
return declare("fox.ArticleCache", null, {
has_storage: 'sessionStorage' in window && window['sessionStorage'] !== null,

View File

@@ -1,3 +1,5 @@
'use strict'
/* global __, ngettext */
define(["dojo/_base/declare"], function (declare) {
return declare("fox.CommonDialogs", null, {
quickAddFeed: function() {

View File

@@ -1,3 +1,5 @@
'use strict'
/* global __, ngettext */
define(["dojo/_base/declare"], function (declare) {
return declare("fox.CommonFilters", null, {
filterDlgCheckAction: function(sender) {

View File

@@ -1,3 +1,5 @@
'use strict'
/* global __, ngettext */
define(["dojo/_base/declare"], function (declare) {
return declare("fox.Feeds", null, {
counters_last_request: 0,

View File

@@ -1,5 +1,5 @@
/* global dijit, __, ngettext, notify */
'use strict';
/* global __, ngettext */
define(["dojo/_base/declare"], function (declare) {
return declare("fox.Headlines", null, {
vgroup_last_feed: undefined,

View File

@@ -19,10 +19,10 @@ const PluginHost = {
this.hooks[name].push(callback);
},
run: function (name, args) {
console.warn('PluginHost::run ' + name);
//console.warn('PluginHost::run ' + name);
if (typeof(this.hooks[name]) != 'undefined')
for (var i = 0; i < this.hooks[name].length; i++)
for (let i = 0; i < this.hooks[name].length; i++)
if (!this.hooks[name][i](args)) break;
}
};

View File

@@ -1,3 +1,5 @@
'use strict'
/* global __, ngettext */
define(["dojo/_base/declare"], function (declare) {
return declare("fox.PrefUsers", null, {

View File

@@ -1,3 +1,5 @@
'use strict'
/* global __, ngettext */
define(["dojo/_base/declare"], function (declare) {
return declare("fox.Utils", null, {
_rpc_seq: 0,
@@ -235,12 +237,6 @@ define(["dojo/_base/declare"], function (declare) {
console.log("RI:", k, "=>", v);
if (k == "dep_ts" && parseInt(getInitParam("dep_ts")) > 0) {
if (parseInt(getInitParam("dep_ts")) < parseInt(v) && getInitParam("reload_on_ts_change")) {
window.location.reload();
}
}
if (k == "daemon_is_running" && v != 1) {
notify_error("<span onclick=\"Utils.explainError(1)\">Update daemon is not running.</span>", true);
return;

View File

@@ -1,3 +1,4 @@
'use strict'
/* global dijit, __ */
let init_params = {};

View File

@@ -1,3 +1,4 @@
'use strict'
/* global dijit, __ */
let Utils;

View File

@@ -1,3 +1,4 @@
'use strict'
/* global dijit,__ */
let Utils;