Check for and use app specified language
Fixed several careless typos
Properly destroy database on IndexedDB logout