Merge branch 'handle-c-locale' into 'master'

Handle C locale.

Closes #236

See merge request jenslody/gnome-shell-extension-openweather!228
master
Jens Lody 5 years ago
commit 8dfc8fab2b
  1. 4
      src/extension.js

@ -155,7 +155,9 @@ const OpenweatherMenuButton = new Lang.Class({
// Get locale, needed for toLocaleString, workaround for gnome-shell 3.24
this.locale = GLib.get_language_names()[0];
if (this.locale.indexOf('_') != -1)
if (this.locale == 'C')
this.locale = 'en';
else if (this.locale.indexOf('_') != -1)
this.locale = this.locale.split("_")[0];
// Create user-agent string from uuid and (if present) the version

Loading…
Cancel
Save