Fixing persistence issues