FIX: Don't show   in date to button (#31352)

This commit is contained in:
Penar Musaraj 2025-02-14 16:53:38 -05:00 committed by GitHub
parent 878514af6e
commit aeb3d717dc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -284,13 +284,11 @@ export default class LocalDatesCreate extends Component {
return dateTime.format("LLLL");
}
@computed("toConfig.dateTime", "toSelected")
formattedTo(dateTime, toSelected) {
const emptyText = toSelected
? " "
@computed("toConfig.dateTime")
formattedTo(dateTime) {
return dateTime.isValid()
? dateTime.format("LLLL")
: i18n("discourse_local_dates.create.form.until");
return dateTime.isValid() ? dateTime.format("LLLL") : emptyText;
}
@action