From c55bdd6ea7ff70881eb6cf41343c4dec3a6b89b2 Mon Sep 17 00:00:00 2001 From: Lucas Date: Sun, 19 Feb 2023 20:22:29 +0000 Subject: [PATCH] backend: rename /view -> /media --- lib/PoorBooru.pm | 6 +++--- views/gallery.tt | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/PoorBooru.pm b/lib/PoorBooru.pm index e054a5c..c09fc8e 100644 --- a/lib/PoorBooru.pm +++ b/lib/PoorBooru.pm @@ -75,7 +75,7 @@ get "/" => sub { my @media = map +{ # XXX point to a cache image_src => "$POORBOORU_API/download/$_", - view_uri => uri_for("/view/$_"), + media_uri => uri_for("/media/$_"), }, @{$data->{media}}; template "gallery" => { @@ -119,7 +119,7 @@ get "/tag/:tag_id_or_name" => sub { my @media = map +{ # XXX point to a cache image_src => "$POORBOORU_API/download/$_", - view_uri => uri_for("/view/$_"), + media_uri => uri_for("/media/$_"), }, @{$data->{media}}; template "gallery" => { @@ -129,7 +129,7 @@ get "/tag/:tag_id_or_name" => sub { }; }; -get "/view/:media_id" => sub { +get "/media/:media_id" => sub { my $media_id = route_parameters->get("media_id"); my $res = api_get("/media/$media_id"); diff --git a/views/gallery.tt b/views/gallery.tt index d0bbdd9..e77a8c6 100644 --- a/views/gallery.tt +++ b/views/gallery.tt @@ -1,6 +1,6 @@