Fix logic for night greeting
This commit is contained in:
parent
b207f51b84
commit
1754470d56
@ -16,7 +16,7 @@ const gree3 = `${CONFIG.greetingAfternoon}\xa0`;
|
|||||||
const gree4 = `${CONFIG.greetingEvening}\xa0`;
|
const gree4 = `${CONFIG.greetingEvening}\xa0`;
|
||||||
|
|
||||||
// Define the hours of the greetings
|
// Define the hours of the greetings
|
||||||
if (hour >= 23 && hour < 5) {
|
if (hour >= 23 || hour < 5) {
|
||||||
document.getElementById('greetings').innerText = gree1 + name;
|
document.getElementById('greetings').innerText = gree1 + name;
|
||||||
} else if (hour >= 6 && hour < 12) {
|
} else if (hour >= 6 && hour < 12) {
|
||||||
document.getElementById('greetings').innerText = gree2 + name;
|
document.getElementById('greetings').innerText = gree2 + name;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user