diff --git a/js/ui/environment.js b/js/ui/environment.js index 4b330e5da..715aca31d 100644 --- a/js/ui/environment.js +++ b/js/ui/environment.js @@ -292,7 +292,8 @@ function init() { // Work around https://bugzilla.mozilla.org/show_bug.cgi?id=508783 Date.prototype.toLocaleFormat = function(format) { - return Shell.util_format_date(format, this.getTime()); + let dt = GLib.DateTime.new_from_unix_local(this.getTime() / 1000); + return dt ? dt.format(format) : ''; }; let slowdownEnv = GLib.getenv('GNOME_SHELL_SLOWDOWN_FACTOR');