From 921e3351ef8b8329246c14e59c55dea1b2a33569 Mon Sep 17 00:00:00 2001 From: Terry Hearst Date: Tue, 19 Mar 2024 01:44:56 -0400 Subject: [PATCH] Fix custom dates not being reset properly --- src/global.gd | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/global.gd b/src/global.gd index 4a4248b..e8a2f38 100644 --- a/src/global.gd +++ b/src/global.gd @@ -120,6 +120,9 @@ func detect_params() -> void: ## Returns true if successful, and will set `custom_word` and possibly `custom_date_str` values accordingly. Returns ## false if unsuccessful and will erase `custom_word` and `custom_date_str`. func parse_custom(value: String) -> bool: + custom_word = "" + custom_date_str = "" + if value.length() == 5: # ...is there an is_alpha function that I missed? var word := value.to_upper() @@ -156,8 +159,6 @@ func parse_custom(value: String) -> bool: custom_date_str = Time.get_date_string_from_unix_time(new_time) return true - custom_word = "" - custom_date_str = "" return false