From acd11f2be8eceebbc5ea56a9cc478d79aeced40c Mon Sep 17 00:00:00 2001 From: Febri Hidayan Date: Mon, 2 Aug 2021 10:26:22 +0700 Subject: [PATCH] fixed: added `thursday` and fixed `lastTime` function error --- resources/lang/en/app.php | 1 + resources/lang/id/app.php | 1 + src/Laratalk.php | 3 ++- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/resources/lang/en/app.php b/resources/lang/en/app.php index 3eefc4d..fa9c596 100644 --- a/resources/lang/en/app.php +++ b/resources/lang/en/app.php @@ -60,6 +60,7 @@ 'settings' => 'Settings', 'sunday' => 'Sunday', 'theme' => 'Theme', + 'thursday' => 'Thursday', 'today' => 'today', 'tuesday' => 'Tuesday', 'type_a_message' => 'Type a message', diff --git a/resources/lang/id/app.php b/resources/lang/id/app.php index 60fb87c..bfce8dc 100644 --- a/resources/lang/id/app.php +++ b/resources/lang/id/app.php @@ -61,6 +61,7 @@ 'settings' => 'Setelan', 'sunday' => 'Minggu', 'theme' => 'Tema', + 'thursday' => 'Kamis', 'today' => 'hari ini', 'tuesday' => 'Selasa', 'type_a_message' => 'Ketik pesan', diff --git a/src/Laratalk.php b/src/Laratalk.php index f407d9d..e42fe5e 100644 --- a/src/Laratalk.php +++ b/src/Laratalk.php @@ -76,12 +76,13 @@ public static function lastTime(object $datetime, $today = false) return $trans['yesterday']; } - if ($countDay >= 1 & $countDay < 7) { + if ($countDay >= 1 && $countDay <= 6) { $days = [ $trans['sunday'], $trans['monday'], $trans['tuesday'], $trans['wednesday'], + $trans['thursday'], $trans['friday'], $trans['saturday'], ];