do not allow locks on undefined
This commit is contained in:
parent
469d7dfebe
commit
628dc12d00
|
@ -7,6 +7,8 @@ var Utils = {};
|
||||||
Utils.runLocked = function(token, cb, task) {
|
Utils.runLocked = function(token, cb, task) {
|
||||||
var self = this;
|
var self = this;
|
||||||
|
|
||||||
|
$.shouldBeDefined(token);
|
||||||
|
|
||||||
Lock.get(token, function(lock) {
|
Lock.get(token, function(lock) {
|
||||||
var _cb = function() {
|
var _cb = function() {
|
||||||
cb.apply(null, arguments);
|
cb.apply(null, arguments);
|
||||||
|
|
Loading…
Reference in New Issue