NodeJsSetupTask: Check for the node executable instead of its directory

We want NodeJs to be downloaded again if nodeBinDir exists but the node
binary is missing.

Fixes https://youtrack.jetbrains.com/issue/KT-34989.
This commit is contained in:
Sebastian Schuberth
2019-11-19 16:05:10 +01:00
committed by Ilya Goncharov
parent 3fcf3d6fea
commit 2760034281
@@ -24,7 +24,7 @@ open class NodeJsSetupTask : DefaultTask() {
init { init {
@Suppress("LeakingThis") @Suppress("LeakingThis")
onlyIf { onlyIf {
settings.download && !env.nodeBinDir.isDirectory settings.download && !File(env.nodeExecutable).isFile
} }
} }