mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-16 11:42:04 +08:00
Fixing onReceiveError for API level >= 23 (#6056)
* Fixing onReceiveError for API level >= 23 * using @ts-ignore as "super as any" is not a valid statement
This commit is contained in:

committed by
Dimitar Topuzov

parent
09431572e5
commit
39acaa8e11
@ -70,7 +70,11 @@ function initializeWebViewClient(): void {
|
||||
let request: any = arguments[1];
|
||||
let error: any = arguments[2];
|
||||
|
||||
super.onReceivedError(view, request, error, null);
|
||||
// before API version 23 there's no onReceiveError with 3 parameters, so it shouldn't come here
|
||||
// but we don't have the onReceivedError with 3 parameters there and that's why we are ignorint tye typescript error
|
||||
// @ts-ignore TS2554
|
||||
super.onReceivedError(view, request, error);
|
||||
|
||||
const owner = this.owner;
|
||||
if (owner) {
|
||||
if (traceEnabled()) {
|
||||
@ -173,4 +177,4 @@ export class WebView extends WebViewBase {
|
||||
return nativeView.reload();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user