simplify sleep code
This commit is contained in:
parent
221063e62b
commit
626fbe4276
1 changed files with 2 additions and 5 deletions
|
@ -119,11 +119,8 @@ define(function (require) {
|
|||
},
|
||||
|
||||
sleep: function sleep(sleepMilliseconds) {
|
||||
var self = this;
|
||||
self.debug('... sleep(' + sleepMilliseconds + ') start');
|
||||
|
||||
return Promise.resolve().delay(sleepMilliseconds)
|
||||
.then(function () { self.debug('... sleep(' + sleepMilliseconds + ') end'); });
|
||||
this.debug('sleeping for ' + sleepMilliseconds + 'ms');
|
||||
return Promise.resolve().delay(sleepMilliseconds);
|
||||
},
|
||||
|
||||
handleError: function (testObj) {
|
||||
|
|
Loading…
Reference in a new issue