Skip to content

Commit 256a6e4

Browse files
committed
Fix core.print_debug to actually print its first argument
1 parent 0867dde commit 256a6e4

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

pkg/src/public/bash-core.sh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ core.panic() {
200200
# err_handler() {
201201
# local exit_code=$1 # Note that this isn't `$?`
202202
# core.print_stacktrace
203-
#
203+
#
204204
# # Note that we're not doing `exit $exit_code` because
205205
# # that is handled automatically
206206
# }
@@ -333,6 +333,8 @@ core.print_info() {
333333
# @description Print a debug message to standard output if the environment variable "DEBUG" is present
334334
# @arg $1 string message
335335
core.print_debug() {
336+
local msg="$1"
337+
336338
if [[ -v DEBUG ]]; then
337339
printf "%s: %s\n" 'Debug' "$msg"
338340
fi
@@ -408,7 +410,7 @@ core.get_package_info() {
408410
unset REPLY; REPLY=
409411
local basalt_package_dir="$1"
410412
local key_name="$2"
411-
413+
412414
local toml_file="$basalt_package_dir/basalt.toml"
413415

414416
if [ ! -f "$toml_file" ]; then
@@ -452,4 +454,4 @@ core.print_die_fn() {
452454
core.print_die() {
453455
core.print_fatal "$1"
454456
exit 1
455-
}
457+
}

0 commit comments

Comments
 (0)