Skip to content

Commit

Permalink
Fix new linter errors
Browse files Browse the repository at this point in the history
  • Loading branch information
rvandermeulen committed Nov 2, 2022
1 parent 62bb45a commit abef20d
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ package org.mozilla.reference.browser.addons
import android.content.Intent
import android.os.Bundle
import android.view.View
import android.widget.TextView
import android.widget.Toast
import androidx.appcompat.app.AppCompatActivity
import androidx.appcompat.widget.SwitchCompat
Expand Down Expand Up @@ -78,11 +77,6 @@ class InstalledAddonDetailsActivity : AppCompatActivity() {
bindRemoveButton(addon)
}

private fun bindVersion(addon: Addon) {
val versionView = findViewById<TextView>(R.id.version_text)
versionView.text = addon.version
}

private fun bindEnableSwitch(addon: Addon) {
val switch = findViewById<SwitchCompat>(R.id.enable_switch)
switch.setState(addon.isEnabled())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,6 @@ class AccountSettingsFragment : PreferenceFragmentCompat() {
SyncEngine.History -> pref_key_sync_history
SyncEngine.Passwords -> pref_key_sync_passwords
SyncEngine.Tabs -> pref_key_sync_tabs
else -> throw IllegalStateException("Accessing unsupported sync engines")
else -> error("Accessing unsupported sync engines")
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class SyncedTabsAdapter(
return when (viewType) {
DeviceViewHolder.LAYOUT_ID -> DeviceViewHolder(itemView)
TabViewHolder.LAYOUT_ID -> TabViewHolder(itemView)
else -> throw IllegalStateException()
else -> error("Unable to create ViewHolder")
}
}

Expand Down

0 comments on commit abef20d

Please sign in to comment.