add persistence to shared preferences