summaryrefslogtreecommitdiff
path: root/modules/tag/controllers
diff options
context:
space:
mode:
authorChad Kieffer <ckieffer@gmail.com>2011-04-23 23:26:40 -0400
committerChad Kieffer <ckieffer@gmail.com>2011-04-23 23:26:40 -0400
commitbbb2a3a30c57592b1baed17533bc3a2e7edb2e8a (patch)
tree8cac738aace3d4ae1d237fcd619a5e2e33275948 /modules/tag/controllers
parent342be9818f8c35dd13c8159960a9f71ae33d4c72 (diff)
parent4c7f27a1a6a4fc71873093dd787de05a8ee6c079 (diff)
Merge branch 'master' of git://github.com/gallery/gallery3
Diffstat (limited to 'modules/tag/controllers')
-rw-r--r--modules/tag/controllers/admin_tags.php11
1 files changed, 1 insertions, 10 deletions
diff --git a/modules/tag/controllers/admin_tags.php b/modules/tag/controllers/admin_tags.php
index 73042a55..fd82bc92 100644
--- a/modules/tag/controllers/admin_tags.php
+++ b/modules/tag/controllers/admin_tags.php
@@ -81,9 +81,7 @@ class Admin_Tags_Controller extends Admin_Controller {
$in_place_edit = InPlaceEdit::factory($tag->name)
->action("admin/tags/rename/$tag->id")
- ->rules(array("required", "length[1,64]"))
- ->messages(array("in_use" => t("There is already a tag with that name")))
- ->callback(array($this, "check_for_duplicate"));
+ ->rules(array("required", "length[1,64]"));
if ($in_place_edit->validate()) {
$old_name = $tag->name;
@@ -101,12 +99,5 @@ class Admin_Tags_Controller extends Admin_Controller {
}
}
- public function check_for_duplicate(Validation $post_data, $field) {
- $tag_exists = ORM::factory("tag")->where("name", "=", $post_data[$field])->count_all();
- if ($tag_exists) {
- $post_data->add_error($field, "in_use");
- }
- }
-
}