fixed db crashes, templates smarter, added some more user data to display