iOS: Fixed bugs when adding to database