monkey-front-core 0.0.198 → 0.0.199

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.
@@ -4685,15 +4685,14 @@ class MonkeyEcxHttpConfigHeaderInterceptor {
4685
4685
  const { url } = request;
4686
4686
  if (this.authService.isTokenMandatory(url)) {
4687
4687
  try {
4688
- const config = await this.config
4688
+ await this.config
4689
4689
  .config()
4690
- .pipe(take(1))
4690
+ .pipe(first((val) => {
4691
+ return !!val;
4692
+ }))
4691
4693
  .toPromise();
4692
- if (!config) {
4693
- await this.onValidateConfig();
4694
- }
4695
4694
  }
4696
- catch (error) {
4695
+ catch (e) {
4697
4696
  // not to do
4698
4697
  }
4699
4698
  }
@@ -4712,26 +4711,6 @@ class MonkeyEcxHttpConfigHeaderInterceptor {
4712
4711
  }))
4713
4712
  .toPromise();
4714
4713
  }
4715
- onValidateConfig() {
4716
- return new Promise((resolve) => {
4717
- let count = 0;
4718
- const interval = setInterval(async () => {
4719
- count += 1;
4720
- if (count > 20) {
4721
- clearInterval(interval);
4722
- resolve(null);
4723
- }
4724
- const config = await this.config
4725
- .config()
4726
- .pipe(take(1))
4727
- .toPromise();
4728
- if (config) {
4729
- clearInterval(interval);
4730
- resolve(null);
4731
- }
4732
- }, 200);
4733
- });
4734
- }
4735
4714
  intercept(request, next) {
4736
4715
  return from(this.handle(request, next));
4737
4716
  }