fix(android): crash problem while loading local html resource (#1010)
This commit is contained in:
parent
b92d6ae014
commit
05c286fc23
|
@ -278,7 +278,7 @@ class WebView extends React.Component<AndroidWebViewProps, State> {
|
||||||
const webViewStyles = [styles.container, styles.webView, style];
|
const webViewStyles = [styles.container, styles.webView, style];
|
||||||
const webViewContainerStyle = [styles.container, containerStyle];
|
const webViewContainerStyle = [styles.container, containerStyle];
|
||||||
|
|
||||||
if (source && 'method' in source) {
|
if (typeof source !== "number" && source && 'method' in source) {
|
||||||
if (source.method === 'POST' && source.headers) {
|
if (source.method === 'POST' && source.headers) {
|
||||||
console.warn(
|
console.warn(
|
||||||
'WebView: `source.headers` is not supported when using POST.',
|
'WebView: `source.headers` is not supported when using POST.',
|
||||||
|
|
Loading…
Reference in New Issue