Skip to content

Commit 7afc371

Browse files
committed
prefix internal methods with underscores
1 parent a5c78a0 commit 7afc371

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

addons/mod_loader/mod_loader_utils.gd

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -61,29 +61,29 @@ static func _loader_log(message: String, mod_name: String, log_type: String = "i
6161

6262
match log_type.to_lower():
6363
"fatal-error":
64-
write_to_log_file(log_message)
65-
write_to_log_file(JSON.print(get_stack(), " "))
64+
_write_to_log_file(log_message)
65+
_write_to_log_file(JSON.print(get_stack(), " "))
6666
assert(false, message)
6767
"error":
6868
printerr(message)
6969
push_error(message)
70-
write_to_log_file(log_message)
70+
_write_to_log_file(log_message)
7171
"warning":
72-
if get_verbosity() >= verbosity_level.WARNING:
72+
if _get_verbosity() >= verbosity_level.WARNING:
7373
print(prefix + message)
7474
push_warning(message)
75-
write_to_log_file(log_message)
75+
_write_to_log_file(log_message)
7676
"info", "success":
77-
if get_verbosity() >= verbosity_level.INFO:
77+
if _get_verbosity() >= verbosity_level.INFO:
7878
print(prefix + message)
79-
write_to_log_file(log_message)
79+
_write_to_log_file(log_message)
8080
"debug":
81-
if get_verbosity() >= verbosity_level.DEBUG:
81+
if _get_verbosity() >= verbosity_level.DEBUG:
8282
print(prefix + message)
83-
write_to_log_file(log_message)
83+
_write_to_log_file(log_message)
8484

8585

86-
static func write_to_log_file(log_entry: String) -> void:
86+
static func _write_to_log_file(log_entry: String) -> void:
8787
var log_file = File.new()
8888

8989
if not log_file.file_exists(MOD_LOG_PATH):
@@ -101,7 +101,7 @@ static func write_to_log_file(log_entry: String) -> void:
101101
log_file.close()
102102

103103

104-
static func get_verbosity() -> int:
104+
static func _get_verbosity() -> int:
105105
if is_running_with_command_line_arg("-vvv") or is_running_with_command_line_arg("--log-debug"):
106106
return verbosity_level.DEBUG
107107
if is_running_with_command_line_arg("-vv") or is_running_with_command_line_arg("--log-info"):

0 commit comments

Comments
 (0)