mirror of
https://github.com/bitwarden/jslib
synced 2025-12-10 21:33:17 +00:00
Remove error Response type check (#731)
* Remove error Response type check
Minimization is impacting type checking in a non-consistent way.
The previous type check works locally,
but not from build artifacts 🤷. We only set `captchaRequired` on
our errors when we want a resubmit with captcha included, so we're safe
keying off that
* linter
This commit is contained in:
@@ -31,10 +31,7 @@ export class ApiActionDirective implements OnChanges {
|
|||||||
(e: any) => {
|
(e: any) => {
|
||||||
this.el.nativeElement.loading = false;
|
this.el.nativeElement.loading = false;
|
||||||
|
|
||||||
if (
|
if ((e as ErrorResponse).captchaRequired) {
|
||||||
(e instanceof ErrorResponse || e.constructor.name === ErrorResponse.name) &&
|
|
||||||
(e as ErrorResponse).captchaRequired
|
|
||||||
) {
|
|
||||||
this.logService.error("Captcha required error response: " + e.getSingleMessage());
|
this.logService.error("Captcha required error response: " + e.getSingleMessage());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user