diff --git a/builds/appchan-x.user.js b/builds/appchan-x.user.js index 363d34597..37859e4a7 100644 --- a/builds/appchan-x.user.js +++ b/builds/appchan-x.user.js @@ -16531,18 +16531,18 @@ if (this.isClone) { return; } - return this.nodes.date.textContent = Time.funk(this.info.date); + return this.nodes.date.textContent = Time.funk(Time, this.info.date); }, createFunc: function(format) { var code; code = format.replace(/%([A-Za-z])/g, function(s, c) { if (c in Time.formatters) { - return "' + this.formatters." + c + ".call(date) + '"; + return "' + Time.formatters." + c + ".call(date) + '"; } else { return s; } }); - return Function('date', "return '" + code + "'"); + return Function('Time', 'date', "return '" + code + "'"); }, day: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'], month: ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'], diff --git a/builds/crx/script.js b/builds/crx/script.js index de698a5cc..49d71a65b 100644 --- a/builds/crx/script.js +++ b/builds/crx/script.js @@ -16551,18 +16551,18 @@ if (this.isClone) { return; } - return this.nodes.date.textContent = Time.funk(this.info.date); + return this.nodes.date.textContent = Time.funk(Time, this.info.date); }, createFunc: function(format) { var code; code = format.replace(/%([A-Za-z])/g, function(s, c) { if (c in Time.formatters) { - return "' + this.formatters." + c + ".call(date) + '"; + return "' + Time.formatters." + c + ".call(date) + '"; } else { return s; } }); - return Function('date', "return '" + code + "'"); + return Function('Time', 'date', "return '" + code + "'"); }, day: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'], month: ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'], diff --git a/src/Miscellaneous/Time.coffee b/src/Miscellaneous/Time.coffee index 0f08befa2..0d290cc63 100755 --- a/src/Miscellaneous/Time.coffee +++ b/src/Miscellaneous/Time.coffee @@ -8,14 +8,14 @@ Time = cb: @node node: -> return if @isClone - @nodes.date.textContent = Time.funk @info.date + @nodes.date.textContent = Time.funk Time, @info.date createFunc: (format) -> code = format.replace /%([A-Za-z])/g, (s, c) -> if c of Time.formatters - "' + this.formatters.#{c}.call(date) + '" + "' + Time.formatters.#{c}.call(date) + '" else s - Function 'date', "return '#{code}'" + Function 'Time', 'date', "return '#{code}'" day: [ 'Sunday' 'Monday'