diff options
author | Andy Lindeman <andy@highgroove.com> | 2011-04-23 12:04:12 -0400 |
---|---|---|
committer | Andy Lindeman <andy@highgroove.com> | 2011-04-23 12:04:43 -0400 |
commit | c101151616033d53587d1435881dae0fa45aeefa (patch) | |
tree | c848494ad67ed0c10cfdf6b7f7f5d00b92717d40 /modules/gallery/libraries | |
parent | 563a25f559a0247b2e3f4e96b191e7138c8e8ea5 (diff) |
Allow tags to be merged by renaming
* Fixes #1628
Diffstat (limited to 'modules/gallery/libraries')
-rw-r--r-- | modules/gallery/libraries/InPlaceEdit.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/modules/gallery/libraries/InPlaceEdit.php b/modules/gallery/libraries/InPlaceEdit.php index 88c30494..739cbb61 100644 --- a/modules/gallery/libraries/InPlaceEdit.php +++ b/modules/gallery/libraries/InPlaceEdit.php @@ -56,8 +56,12 @@ class InPlaceEdit_Core { } public function validate() { - $post = Validation::factory($_POST) - ->add_callbacks("input", $this->callback); + $post = Validation::factory($_POST); + + if (!empty($this->callback)) { + $post->add_callbacks("input", $this->callback); + } + foreach ($this->rules as $rule) { $post->add_rules("input", $rule); } |