-
-
Save belden/9448c4df19df7be7fa9fe2f01ad4d7eb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ember.RSVP.defer = function(promiseLabel) { | |
var re = new RegExp(str); | |
if (promiseLabel.match(re)) { | |
var doom = Ember.RSVP.reject({ | |
errors: JSON.stringify([{ | |
'token':'^error_duplicate_store_name^', | |
'args': ['luciferase-tiddley-store', 'Organization > ramson-gent-region'] | |
}]) | |
}); | |
var deferred = origRSVPDefer.apply(this, arguments); | |
deferred.promise = doom; | |
return deferred; | |
} | |
return origRSVPDefer.apply(this, arguments); | |
}; | |
return origRSVPDefer; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment