fixed error.rb model