]> git.sesse.net Git - pr0n/blobdiff - perl/Sesse/pr0n/Index.pm
Make sure rotation and selection invalidate the listing cache.
[pr0n] / perl / Sesse / pr0n / Index.pm
index e85ab6e7ae0e281627da373a820994f630ddee18..41b4db1689d1be44e5fadb64c416beb5e78d533c 100644 (file)
@@ -82,7 +82,7 @@ sub handler {
                $num = undef;
        }
 
-       my $ref = $dbh->selectrow_hashref('SELECT name,date,EXTRACT(EPOCH FROM last_update) AS last_update FROM events WHERE id=? AND vhost=?',
+       $ref = $dbh->selectrow_hashref('SELECT name,date,EXTRACT(EPOCH FROM last_update) AS last_update FROM events WHERE id=? AND vhost=?',
                undef, $event, $r->get_server_name)
                or error($r, "Could not find event $event", 404, "File not found");
 
@@ -159,6 +159,7 @@ sub handler {
                # Print out all thumbnails
                if ($rot == 1) {
                        $r->print("    <form method=\"post\" action=\"/rotate\">\n");
+                       $r->print("      <input type=\"hidden\" name=\"event\" value=\"$event\" />\n");
                
                        while (my $ref = $q->fetchrow_hashref()) {
                                my $imgsz = "";