Skip to content

Commit 4749254

Browse files
committed
chore: Add clarifying parentheses for the / operator
This is a fixup for e2dd087 to silence an IDE inspection hint that is not also covered by a Detekt rule. Arguably, this is still more readable than re-introducing `.resolve()`. Signed-off-by: Sebastian Schuberth <[email protected]>
1 parent 306135b commit 4749254

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

plugins/package-managers/pub/src/main/kotlin/Pub.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ class Pub(override val descriptor: PluginDescriptor = PubFactory.descriptor, pri
172172

173173
private val flutterHome by lazy {
174174
Os.getPathFromEnvironment(flutterCommand)?.realFile?.parentFile?.parentFile
175-
?: Os.env["FLUTTER_HOME"]?.let { File(it) } ?: flutterInstallDir / "flutter"
175+
?: Os.env["FLUTTER_HOME"]?.let { File(it) } ?: (flutterInstallDir / "flutter")
176176
}
177177

178178
private val flutterAbsolutePath = flutterHome / "bin"

utils/ort/src/main/kotlin/Environment.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ val ortDataDirectory by lazy {
123123
it.isEmpty()
124124
}?.let {
125125
File(it)
126-
} ?: Os.userHomeDirectory / ".ort"
126+
} ?: (Os.userHomeDirectory / ".ort")
127127
}
128128

129129
/**
@@ -134,7 +134,7 @@ val ortConfigDirectory by lazy {
134134
it.isEmpty()
135135
}?.let {
136136
File(it)
137-
} ?: ortDataDirectory / "config"
137+
} ?: (ortDataDirectory / "config")
138138
}
139139

140140
/**
@@ -145,5 +145,5 @@ val ortToolsDirectory by lazy {
145145
it.isEmpty()
146146
}?.let {
147147
File(it)
148-
} ?: ortDataDirectory / "tools"
148+
} ?: (ortDataDirectory / "tools")
149149
}

0 commit comments

Comments
 (0)