changed model to fix save bug