summaryrefslogtreecommitdiff
path: root/lib/VNDB/Handler/Producers.pm
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2008-11-22 09:42:00 +0100
committerYorhel <git@yorhel.nl>2008-11-22 09:42:00 +0100
commitaac83c8b840f62d3febf2212b86bf7cf40eb3fa1 (patch)
tree2168e7f510a68913f8829e0a69a9b401f2cfa7d7 /lib/VNDB/Handler/Producers.pm
parent1104001784aa76b9ad8c454336b103d8365cb779 (diff)
Wrote a generic function to handle all /[vrp]+/(lock|hide) URIs
They pretty much all work the same anyway
Diffstat (limited to 'lib/VNDB/Handler/Producers.pm')
-rw-r--r--lib/VNDB/Handler/Producers.pm12
1 files changed, 0 insertions, 12 deletions
diff --git a/lib/VNDB/Handler/Producers.pm b/lib/VNDB/Handler/Producers.pm
index 234280b7..27f3a852 100644
--- a/lib/VNDB/Handler/Producers.pm
+++ b/lib/VNDB/Handler/Producers.pm
@@ -11,7 +11,6 @@ YAWF::register(
qr{p([1-9]\d*)(?:\.([1-9]\d*))?} => \&page,
qr{p(?:([1-9]\d*)(?:\.([1-9]\d*))?/edit|/new)}
=> \&edit,
- qr{p([1-9]\d*)/(lock|hide)} => \&mod,
qr{p/([a-z0]|all)} => \&list,
);
@@ -166,17 +165,6 @@ sub edit {
}
-# /hide and /lock
-sub mod {
- my($self, $pid, $act) = @_;
- return $self->htmlDenied if !$self->authCan($act eq 'hide' ? 'del' : 'lock');
- my $p = $self->dbProducerGet(id => $pid)->[0];
- return 404 if !$p->{id};
- $self->dbProducerMod($pid, $act eq 'hide' ? (hidden => !$p->{hidden}) : (locked => !$p->{locked}));
- $self->resRedirect("/p$pid", 'temp');
-}
-
-
sub list {
my($self, $char) = @_;