Last active
July 17, 2020 13:34
-
-
Save ataulm/1c3a2d97a4bd46139271dde6bbd7b712 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
internal fun createErrorThemesAndStylesIssue(detectorClass: KClass<out Detector>, scope: EnumSet<Scope>): Issue { | |
return createThemesAndStylesIssue(detectorClass, Severity.ERROR, scope) | |
} | |
internal fun createWarningThemesAndStylesIssue(detectorClass: KClass<out Detector>, scope: EnumSet<Scope>): Issue { | |
return createThemesAndStylesIssue(detectorClass, Severity.WARNING, scope) | |
} | |
private fun createThemesAndStylesIssue( | |
detectorClass: KClass<out Detector>, | |
severity: Severity, | |
scope: EnumSet<Scope> | |
) = Issue.create( | |
id = detectorClass.simpleName!!, | |
briefDescription = "${detectorClass.simpleName}", | |
explanation = "Check ${detectorClass.simpleName} in the Monzo project for details.", | |
category = Category.create("Themes and styles", 75), | |
severity = severity, | |
implementation = Implementation(detectorClass.java, scope) | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment