Use WCF/Timer/Repeating in WCF/Date/Time/Relative
authorTim Düsterhus <duesterhus@woltlab.com>
Mon, 25 May 2015 01:00:05 +0000 (03:00 +0200)
committerTim Düsterhus <duesterhus@woltlab.com>
Mon, 25 May 2015 01:00:05 +0000 (03:00 +0200)
wcfsetup/install/files/js/WoltLab/WCF/Date/Time/Relative.js

index 253d95f58ab5be8c3743eadf67c9bc2ad7a9bdc0..2fdb2b0b8662cd08ac57e9c7df42748fb7da36ae 100644 (file)
@@ -6,7 +6,7 @@
  * @license    GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
  * @module     WoltLab/WCF/Date/Time/Relative
  */
-define(['DOM/ChangeListener', 'Language'], function(DOMChangeListener, Language) {
+define(['DOM/ChangeListener', 'Language', 'WoltLab/WCF/Timer/Repeating'], function(DOMChangeListener, Language, Repeating) {
        "use strict";
        
        var _elements = null;
@@ -25,7 +25,7 @@ define(['DOM/ChangeListener', 'Language'], function(DOMChangeListener, Language)
                        
                        this._refresh();
                        
-                       new WCF.PeriodicalExecuter(this._refresh.bind(this), 60000);
+                       new Repeating(this._refresh.bind(this), 60000);
                        
                        DOMChangeListener.add('WoltLab/WCF/Date/Time/Relative', this._refresh.bind(this));
                },