implemented save on model