Refactored code into flash, login, and auth services; modified settings structure