@indigina/kendo 1.0.155-beta → 1.0.164-beta

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1245,9 +1245,6 @@
1245
1245
  function IndiginaModule() {
1246
1246
  }
1247
1247
  IndiginaModule.forRoot = function (configuration) {
1248
- if (!configuration.appSettings.apiUrl.endsWith('/')) {
1249
- configuration.appSettings.apiUrl += '/';
1250
- }
1251
1248
  return {
1252
1249
  ngModule: IndiginaModule,
1253
1250
  providers: [
@@ -1634,6 +1631,7 @@
1634
1631
  ]; };
1635
1632
 
1636
1633
  var absoluteUrlRegExp = /^http(s)?:\/\//;
1634
+ var slash = '/';
1637
1635
  var HttpService = /** @class */ (function () {
1638
1636
  function HttpService(appToastrService, httpClient, appSettings, translate, router, settingsService) {
1639
1637
  this.appToastrService = appToastrService;
@@ -1664,7 +1662,14 @@
1664
1662
  return this.httpClient.put(this.createUrl(path), data).pipe(operators.tap(function () { return _this.showSuccessMessage(successTranslateMessage !== null && successTranslateMessage !== void 0 ? successTranslateMessage : 'ToastrMessages.SavedSuccessfully'); }), operators.catchError(function (err) { return _this.handleServerError(err); }));
1665
1663
  };
1666
1664
  HttpService.prototype.createUrl = function (path) {
1667
- return absoluteUrlRegExp.test(path) ? path : this.appSettings.apiUrl + path;
1665
+ if (absoluteUrlRegExp.test(path)) {
1666
+ return path;
1667
+ }
1668
+ path = path.startsWith(slash) ? path.slice(1) : path;
1669
+ var apiUrl = this.appSettings.apiUrl.endsWith(slash)
1670
+ ? this.appSettings.apiUrl
1671
+ : this.appSettings.apiUrl + slash;
1672
+ return apiUrl + path;
1668
1673
  };
1669
1674
  HttpService.prototype.handleServerError = function (error) {
1670
1675
  if (error.error instanceof ErrorEvent) {
@@ -2034,6 +2039,7 @@
2034
2039
  clickedOutside: [{ type: i0.HostListener, args: ['document:click', ['$event'],] }]
2035
2040
  };
2036
2041
 
2042
+ var resetPasswordCanceledErrorCode = 'AADB2C90091';
2037
2043
  var AzureLoginCallbackComponent = /** @class */ (function () {
2038
2044
  function AzureLoginCallbackComponent(authService, settingsService, router) {
2039
2045
  this.authService = authService;
@@ -2042,14 +2048,16 @@
2042
2048
  }
2043
2049
  AzureLoginCallbackComponent.prototype.ngOnInit = function () {
2044
2050
  var _this = this;
2045
- this.authService
2046
- .handleRedirectObservable()
2047
- .subscribe(function (result) {
2051
+ this.authService.handleRedirectObservable().subscribe(function (result) {
2048
2052
  if (result) {
2049
2053
  _this.settingsService.setToken(result.idToken);
2050
2054
  _this.authService.instance.setActiveAccount(result.account);
2051
2055
  }
2052
2056
  _this.router.navigate(['home']);
2057
+ }, function (error) {
2058
+ if (error.errorMessage.includes(resetPasswordCanceledErrorCode)) {
2059
+ _this.router.navigate(['home']);
2060
+ }
2053
2061
  });
2054
2062
  };
2055
2063
  AzureLoginCallbackComponent.prototype.logout = function () {
@@ -3188,9 +3196,6 @@
3188
3196
  function KendoModule() {
3189
3197
  }
3190
3198
  KendoModule.forRoot = function (config) {
3191
- if (!config.appSettings.apiUrl.endsWith('/')) {
3192
- config.appSettings.apiUrl += '/';
3193
- }
3194
3199
  return {
3195
3200
  ngModule: KendoModule,
3196
3201
  providers: [