mongoid/mongoid — pull request #1622 by semaperepelitsa (2012-01-21 14:34:36+00:00)
Title: "Localized" refactoring

I have spotted many places with condition `if field.localized? then ... else ...`. This is not a good object-oriented programming. I've moved that logic inside fields classes. There are a few places left but I have a question for now. What is your policy for using strings versus symbols in field names? Criterion::Optional mostly uses symbols, Criterion::Selector uses whatever the argument is except for localized fields it makes strings. A Serializable field's name is a string. And what about my idea overall?