@@ -305,7 +305,7 @@ function dateUpdated($row, $wrap = null) {
305
305
306
306
if ($ dateUpdated ) {
307
307
$ updateUser = Gdn::userModel ()->getID ($ updateUserID );
308
- $ dateUpdatedFormatted = formatDateCustom ($ dateUpdated );
308
+ $ dateUpdatedFormatted = formatDateCustom ($ dateUpdated, false );
309
309
if ($ updateUser && $ insertUserID != $ updateUserID ) {
310
310
$ title = sprintf (t ('Edited %s by %s. ' ), $ dateUpdatedFormatted , val ('Name ' , $ updateUser ));
311
311
$ link = userAnchor ($ updateUser );
@@ -990,8 +990,9 @@ function discussionUrl($discussion, $page = '', $withDomain = true) {
990
990
}
991
991
992
992
if (!function_exists ('formatDateCustom ' )) {
993
- function formatDateCustom ($ timestamp ) {
994
- $ dateFormatted = Gdn::getContainer ()->get (DateTimeFormatter::class)->formatDate ($ timestamp , false , '%a, %b %e %Y ' );
993
+ function formatDateCustom ($ timestamp , $ showDayOfWeek =true ) {
994
+ $ dateFormat = $ showDayOfWeek ? '%a, %b %e, %Y ' : '%b %e, %Y ' ;
995
+ $ dateFormatted = Gdn::getContainer ()->get (DateTimeFormatter::class)->formatDate ($ timestamp , false , $ dateFormat );
995
996
$ timeFormatted = Gdn::getContainer ()->get (DateTimeFormatter::class)->formatDate ($ timestamp , false , '%I:%M %p ' );
996
997
return sprintf ('%1$s at %2$s ' , $ dateFormatted , $ timeFormatted );
997
998
}
0 commit comments