Fixed possible Android java.lang.NullPointerException in InAppBrowserActivity.onCreateOptionsMenu about webView.getTitle()

This commit is contained in:
Lorenzo Pichilli 2022-05-05 22:00:44 +02:00
parent f58eea323a
commit ef9580b287
3 changed files with 6 additions and 2 deletions

View File

@ -1,3 +1,7 @@
## 5.4.3+7
- Fixed possible Android java.lang.NullPointerException in InAppBrowserActivity.onCreateOptionsMenu about webView.getTitle()
## 5.4.3+6
- Fixed "iOS flutter_inappwebview/URLRequest.swift:13: Fatal error: Unexpectedly found nil while unwrapping an Optional value" [#1173](https://github.com/pichillilorenzo/flutter_inappwebview/issues/1173)

View File

@ -208,7 +208,7 @@ public class InAppBrowserActivity extends AppCompatActivity implements InAppBrow
menu = m;
if (actionBar != null && (options.toolbarTopFixedTitle == null || options.toolbarTopFixedTitle.isEmpty()))
actionBar.setTitle(webView.getTitle());
actionBar.setTitle(webView != null ? webView.getTitle() : "");
if (menu == null)
return super.onCreateOptionsMenu(m);

View File

@ -1,6 +1,6 @@
name: flutter_inappwebview
description: A Flutter plugin that allows you to add an inline webview, to use an headless webview, and to open an in-app browser window.
version: 5.4.3+6
version: 5.4.3+7
homepage: https://github.com/pichillilorenzo/flutter_inappwebview
environment: