From c87f4ff5acad64fedc19a8b8aaf7569899e67bdd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Gigandet?= Date: Fri, 26 May 2023 16:50:22 +0200 Subject: [PATCH] fix: product added by user url #8421 --- lib/ProductOpener/Display.pm | 2 +- lib/ProductOpener/Tags.pm | 13 ------------- 2 files changed, 1 insertion(+), 14 deletions(-) diff --git a/lib/ProductOpener/Display.pm b/lib/ProductOpener/Display.pm index 00a12ba9869b1..3d6e4a32d2ace 100644 --- a/lib/ProductOpener/Display.pm +++ b/lib/ProductOpener/Display.pm @@ -3904,7 +3904,7 @@ HTML $user_template_data_ref->{links} = [ { text => sprintf(lang('contributors_products'), $products_title), - url => canonicalize_tag_link("contributors", get_string_id_for_lang("no_language", $tagid)), + url => canonicalize_tag_link("users", get_string_id_for_lang("no_language", $tagid)), }, { text => sprintf(lang('editors_products'), $products_title), diff --git a/lib/ProductOpener/Tags.pm b/lib/ProductOpener/Tags.pm index 932b1e16b4337..784e5e2e73b82 100644 --- a/lib/ProductOpener/Tags.pm +++ b/lib/ProductOpener/Tags.pm @@ -3992,11 +3992,8 @@ sub canonicalize_tag_link ($tagtype, $tagid) { die "ERROR: canonicalize_tag_link called for a taxonomy tagtype: $tagtype - tagid: $tagid - $!"; } - my $tag_lc = $lc; - if ($tagtype eq 'missions') { if ($tagid =~ /\./) { - $tag_lc = $`; $tagid = $'; } } @@ -4008,19 +4005,9 @@ sub canonicalize_tag_link ($tagtype, $tagid) { my $link = "/$path/" . URI::Escape::XS::encodeURIComponent($tagid); - #if ($tag_lc ne $lc) { - # my $test = ''; - # if ($data_root =~ /-test/) { - # $test = "-test"; - # } - # $link = "http://" . $tag_lc . $test . "." . $server_domain . $link; - #} - - #print STDERR "tagtype: $tagtype - $lc: $lc - lang: $lang - link: $link\n"; $log->info("canonicalize_tag_link $tagtype $tagid $path $link") if $log->is_info(); return $link; - } sub export_tags_hierarchy ($lc, $tagtype) {