-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor network detectors to kotlin #752
base: main
Are you sure you want to change the base?
Conversation
@@ -116,6 +116,9 @@ public Builder carrier(@Nullable Carrier carrier) { | |||
} | |||
|
|||
public Builder subType(@Nullable String subType) { | |||
if ((subType != null) && subType.isEmpty()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if ((subType != null) && subType.isEmpty()) { | |
if ((subType.isNullOrEmpty()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That will NPE right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is indeed super nice! And does this also monkey patch the java classes? Because this is still java.....
Follow up from #736, this refactors the two network detectors to be in kotlin, and simplifies a few things.