Correctly test for boolean input's truthiness

It gets cast to a string! Eep!
This commit is contained in:
Jess Bees
2022-03-29 09:39:03 -04:00
parent f511fa4665
commit a598b2af14
3 changed files with 5 additions and 3 deletions

3
dist/index.js vendored
View File

@@ -7473,7 +7473,8 @@ process.on('SIGINT', cancelHandler)
process.on('SIGTERM', cancelHandler)
// Main
if (core.getInput("emit_telemetry")) {
// Boolean inputs are stringified, but manually convert this input just in case that changes in the future.
if (core.getInput("emit_telemetry").toString() === "true") {
__nccwpck_require__(9557)
} else {
main()

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

View File

@@ -52,7 +52,8 @@ process.on('SIGINT', cancelHandler)
process.on('SIGTERM', cancelHandler)
// Main
if (core.getInput("emit_telemetry")) {
// Boolean inputs are stringified, but manually convert this input just in case that changes in the future.
if (core.getInput("emit_telemetry").toString() === "true") {
require('./pre')
} else {
main()