mirror of
https://github.com/tw93/Mole.git
synced 2026-02-08 10:19:20 +00:00
refactor: standardize epoch time retrieval with get_epoch_seconds and ensure locale-independent string transformations.
This commit is contained in:
@@ -200,7 +200,7 @@ is_cache_valid() {
|
||||
return 1
|
||||
fi
|
||||
|
||||
local cache_age=$(($(date +%s) - $(get_file_mtime "$cache_file")))
|
||||
local cache_age=$(($(get_epoch_seconds) - $(get_file_mtime "$cache_file")))
|
||||
[[ $cache_age -lt $ttl ]]
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user