diff options
| author | wn_ <invalid@email.com> | 2024-12-15 18:14:42 +0000 |
|---|---|---|
| committer | wn_ <invalid@email.com> | 2024-12-15 18:39:03 +0000 |
| commit | f9b2291c28e7036276134aac84ec456fbd297d30 (patch) | |
| tree | 82299fdc13a4e0950126c0ec889d4a9e020748f6 /classes/TimeHelper.php | |
| parent | 119c7f13dcb9b91368304e3affd0219108ec490f (diff) | |
Don't bother passing unused arguments to 'TimeHelper::make_local_datetime()'.
There's no point in passing '$long' unless '$no_smart_dt' is set to 'true'.
Diffstat (limited to 'classes/TimeHelper.php')
| -rw-r--r-- | classes/TimeHelper.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/classes/TimeHelper.php b/classes/TimeHelper.php index 5b140e913..c39391eea 100644 --- a/classes/TimeHelper.php +++ b/classes/TimeHelper.php @@ -26,7 +26,10 @@ class TimeHelper { } } - static function make_local_datetime(?string $timestamp, bool $long, ?int $owner_uid = null, + /** + * @param bool $long Whether to display the datetime in a 'long' format. Only used if $no_smart_dt is true. + */ + static function make_local_datetime(?string $timestamp, bool $long = false, ?int $owner_uid = null, bool $no_smart_dt = false, bool $eta_min = false): string { if (!$owner_uid) $owner_uid = $_SESSION['uid']; |