More refactoring to Auth and model handling