V8: Angular Divorce: isUndefined (#7856)

* Bye bye angular.isUndefinied & hello Utilities.isUndefined

* Add utilities.js to lazyload initialise scripts

* Remove utilities.js as copied over client folder
This commit is contained in:
Warren Buckley
2020-12-10 00:21:34 +00:00
committed by GitHub
parent 7a71bc5410
commit e38e5d6577
10 changed files with 22 additions and 13 deletions

View File

@@ -1377,13 +1377,13 @@ function MockHttpExpectation(method, url, data, headers) {
};
this.matchHeaders = function (h) {
if (angular.isUndefined(headers)) return true;
if (Utilities.isUndefined(headers)) return true;
if (angular.isFunction(headers)) return headers(h);
return angular.equals(headers, h);
};
this.matchData = function (d) {
if (angular.isUndefined(data)) return true;
if (Utilities.isUndefined(data)) return true;
if (data && angular.isFunction(data.test)) return data.test(d);
if (data && !Utilities.isString(data)) return angular.toJson(data) == d;
return data == d;