bmidget/kohana-formo — pull request #195 by shadlaws (2013-04-28 14:15:32+00:00)
Title: Allow Formo::add_rule() to use a syntax similar to Validation::rule().

This allows a syntax similar to Validation::rule() and Formo::remove_rule() as
```php
$field->add_rule($rule);
$field->add_rule($rule, $params);
```

or a syntax similar to Validation::rules() and Formo::add_rules() as
```php
$field->add_rule(array($rule));
$field->add_rule(array($rule, $params));
```

Not only does this make our implementation code a little cleaner (working on updating Gallery to Kohana 3.3 at https://github.com/gallery/gallery3/tree/kohana_3), but it also makes it easier to extend add_rule(). FWIW, I'm extending add_rule() to allow inline error message definitions (inline as opposed to in message files, that is)...

Thanks!