Implemented prefs module properly, data is actually being persisted now