ArgumentError should be wrapped in a custom Mongoid error class

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Done
    • 2.3.1
    • Affects Version/s: None
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Rescuing ArgumentError is pretty nerve racking in an application at the model or controller level. It should be caught when typecasting dates and a Mongoid wrapped error should be thrown in its place. Perhaps something more descriptive like Mongoid::InvalidDateFormat or even something generic to typecasting failure Mongoid::TypecastFailure

              Assignee:
              Unassigned
              Reporter:
              seankibler
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: