From 37c4da675c5b1839b0d3ee1c2d1f9840ca9730f3 Mon Sep 17 00:00:00 2001 From: Marco Pessotto Date: Thu, 7 Sep 2023 17:05:12 +0200 Subject: [PATCH] Do not display the ore link in special pages --- lib/AmuseWikiFarm/Role/Controller/Text.pm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/AmuseWikiFarm/Role/Controller/Text.pm b/lib/AmuseWikiFarm/Role/Controller/Text.pm index e318735b..fd6fe198 100644 --- a/lib/AmuseWikiFarm/Role/Controller/Text.pm +++ b/lib/AmuseWikiFarm/Role/Controller/Text.pm @@ -103,8 +103,11 @@ sub match :Chained('base') PathPart('') :CaptureArgs(1) { } $c->stash(page_title => HTML::Entities::decode_entities($text->title), text_json_api => $c->uri_for($text->full_header_api), - ore_rdf_link => $c->uri_for($text->full_ore_rdf_uri), show_preview_only => $show_preview_only); + if ($c->stash->{f_class} eq 'text') { + $c->stash(ore_rdf_link => $c->uri_for($text->full_ore_rdf_uri)); + } + } elsif (my $attach = $site->attachments->by_uri($canonical . $append_ext)) { log_debug { "Found attachment $canonical$append_ext" };