So I don't have a model called Person, but I use hashes like {:name => "Siddharth", :sex => "Y"}. Great. Now I want to validate the presence of certain fields before persisting to the database. What do I do?
Module PersonValidation
function validate_presence_of_name(person_hash)
person_hash[:errors][:name] = "EEENKKK!" unless person_hash[:name]
end
...
...