Language detection from localStorage is broken