mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FIX: Local time not updating between user cards (#9564)
The local time was not updating between user cards because the computed property was not used correctly. There's an old saying in Tennessee — I know it's in Texas, probably in Tennessee — that says, fool me once computed properties, shame on — shame on you. Fool me — you can't get fooled again.
This commit is contained in:
@@ -75,9 +75,8 @@ export default Component.extend(CardContentsBase, CanCheckEmails, CleansUp, {
|
||||
return user.resolvedTimezone();
|
||||
},
|
||||
|
||||
@discourseComputed()
|
||||
formattedUserLocalTime() {
|
||||
const timezone = this.userTimezone;
|
||||
@discourseComputed("userTimezone")
|
||||
formattedUserLocalTime(timezone) {
|
||||
return moment.tz(timezone).format(I18n.t("dates.time_with_zone"));
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user