Skip to content

Commit 184219d

Browse files
fix: compare strings, not object references (#46)
1 parent e609acc commit 184219d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

android/src/main/java/com/reactnativecommunity/webview/RNCWebViewManager.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1079,7 +1079,7 @@ public void onPermissionRequest(final PermissionRequest request) {
10791079
final int port = originUri.getPort();
10801080
String origin = scheme + "://" + originUri.getHost();
10811081

1082-
if (port > 0 && ((scheme == "http" && port != 80) || (scheme == "https" && port != 443))) {
1082+
if (port > 0 && (("http".equals(scheme) && port != 80) || ("https".equals(scheme) && port != 443))) {
10831083
origin += ":" + port;
10841084
}
10851085

0 commit comments

Comments
 (0)