Table Saving and Logout working properly