Skip to content

Commit feddb3c

Browse files
committed
fix #78 networkConnectionSettings methods weren't using correct logic
1 parent cbcdee8 commit feddb3c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/main/java/io/appium/java_client/NetworkConnectionSetting.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,11 @@ public NetworkConnectionSetting(int bitmask) {
3434
value = bitmask;
3535
}
3636

37-
public boolean airplaneModeEnabled() { return (value & airplaneMode) == 1; }
37+
public boolean airplaneModeEnabled() { return (value & airplaneMode) != 0; }
3838

39-
public boolean wifiEnabled() { return (value & wifi) == 1; }
39+
public boolean wifiEnabled() { return (value & wifi) != 0; }
4040

41-
public boolean dataEnabled() { return (value & data) == 1; }
41+
public boolean dataEnabled() { return (value & data) != 0; }
4242

4343
public void setAirplaneMode(boolean enable) {
4444
if (enable) {

0 commit comments

Comments
 (0)