Skip to content

Commit

Permalink
♻️ Refactor KotoolsSamplesJvmPlugin.apply(Project) method
Browse files Browse the repository at this point in the history
  • Loading branch information
LVMVRQUXL committed Sep 10, 2024
1 parent 8fe0960 commit 67adc16
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,17 @@ public class KotoolsSamplesJvmPlugin : Plugin<Project> {

/** Applies this plugin to the specified [project]. */
override fun apply(project: Project) {
project.checkKotlinJvmPlugin()
TODO("Not yet implemented")
}

private fun Project.checkKotlinJvmPlugin() {
val projectHasKotlinJvmPlugin: Boolean =
project.pluginManager.hasPlugin("org.jetbrains.kotlin.jvm")
this.pluginManager.hasPlugin("org.jetbrains.kotlin.jvm")
if (!projectHasKotlinJvmPlugin) {
val message = KotlinJvmPluginNotFound(project)
val message = KotlinJvmPluginNotFound(this)
error(message)
}
TODO("Not yet implemented")
}

// ------------------------------ Conversions ------------------------------
Expand Down

0 comments on commit 67adc16

Please sign in to comment.