]> Untitled Git - lemmy.git/commitdiff
Don't show cake day indicator on the same year / day of user registration, instead...
authorFilip Duricic <fdjuricic98@gmail.com>
Sat, 11 Jul 2020 01:38:01 +0000 (03:38 +0200)
committerGitHub <noreply@github.com>
Sat, 11 Jul 2020 01:38:01 +0000 (21:38 -0400)
ui/src/utils.ts

index 6276519ba2a382765b84ba6622f2877c72f3ec7f..2bede77704aeee5553a48df68453a2ac810ea8ad 100644 (file)
@@ -496,7 +496,8 @@ export function isCakeDay(published: string): boolean {
 
   return (
     userCreationDate.date() === currentDate.date() &&
-    userCreationDate.month() === currentDate.month()
+    userCreationDate.month() === currentDate.month() &&
+    userCreationDate.year() !== currentDate.year()
   );
 }