Resolve lint errors and reduce inspection severity to info

This commit is contained in:
Sean Mac Gillicuddy 2019-09-03 12:13:30 +01:00
parent e7c3d5dcdf
commit b08b36a757
4 changed files with 14 additions and 12 deletions

View File

@ -343,7 +343,7 @@
<inspection_tool class="RemoveForLoopIndices" enabled="true" level="ERROR" enabled_by_default="true" />
<inspection_tool class="RemoveRedundantBackticks" enabled="true" level="ERROR" enabled_by_default="true" />
<inspection_tool class="RemoveRedundantCallsOfConversionMethods" enabled="true" level="ERROR" enabled_by_default="true" />
<inspection_tool class="RemoveRedundantQualifierName" enabled="true" level="WEAK WARNING" enabled_by_default="true" />
<inspection_tool class="RemoveRedundantQualifierName" enabled="true" level="INFORMATION" enabled_by_default="true" />
<inspection_tool class="RemoveRedundantSpreadOperator" enabled="true" level="ERROR" enabled_by_default="true" />
<inspection_tool class="RemoveSetterParameterType" enabled="true" level="ERROR" enabled_by_default="true" />
<inspection_tool class="RemoveSingleExpressionStringTemplate" enabled="true" level="ERROR" enabled_by_default="true" />

View File

@ -22,4 +22,4 @@ import kotlin.annotation.AnnotationRetention.RUNTIME
@Scope
@Retention(RUNTIME)
annotation class ServiceScope
annotation class ServiceScope

View File

@ -67,4 +67,3 @@ class ServiceModule {
): HotspotNotificationManager =
HotspotNotificationManager(notificationManager, context)
}

View File

@ -2,7 +2,6 @@ package org.kiwix.kiwixmobile.utils
import android.net.wifi.WifiConfiguration
import org.kiwix.kiwixmobile.R
import org.kiwix.kiwixmobile.R.string
import org.kiwix.kiwixmobile.zim_manager.fileselect_view.adapter.BooksOnDiskListItem.BookOnDisk
sealed class KiwixDialog(
@ -39,7 +38,10 @@ sealed class KiwixDialog(
)
object StoragePermissionRationale : KiwixDialog(
null, R.string.request_storage, android.R.string.yes, android.R.string.cancel
null,
R.string.request_storage,
android.R.string.yes,
android.R.string.cancel
)
object EnableWifiP2pServices : KiwixDialog(
@ -71,13 +73,14 @@ sealed class KiwixDialog(
)
}
data class StartHotspotManually(val neutralMessage: Int = string.hotspot_dialog_neutral_button) :
KiwixDialog(
string.hotspot_dialog_title,
string.hotspot_dialog_message,
string.go_to_settings_label,
null
)
data class StartHotspotManually(
val neutralMessage: Int = R.string.hotspot_dialog_neutral_button
) : KiwixDialog(
R.string.hotspot_dialog_title,
R.string.hotspot_dialog_message,
R.string.go_to_settings_label,
null
)
data class FileTransferConfirmation(override val args: Array<out Any>) : KiwixDialog(
null, R.string.transfer_to, R.string.yes, android.R.string.cancel