Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public open class PackagerConnectionSettings(private val appContext: Context) {
public val packageName: String = appContext.packageName

init {
resetDebugServerHost()
_cachedOrOverrideHost = null
}

public open var debugServerHost: String
Expand Down Expand Up @@ -50,13 +50,16 @@ public open class PackagerConnectionSettings(private val appContext: Context) {
}
set(host) {
if (host.isEmpty()) {
preferences.edit().remove(PREFS_DEBUG_SERVER_HOST_KEY).apply()
_cachedOrOverrideHost = null
} else {
preferences.edit().putString(PREFS_DEBUG_SERVER_HOST_KEY, host).apply()
_cachedOrOverrideHost = host
}
}

public open fun resetDebugServerHost() {
preferences.edit().remove(PREFS_DEBUG_SERVER_HOST_KEY).apply()
_cachedOrOverrideHost = null
}

Expand Down
Loading