From 2e976696c942886d7d3875ba569696693f1a8fff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andrej=20Rama=C5=A1euski?= <andrej@x2.cz> Date: Thu, 24 Apr 2025 00:37:29 +0200 Subject: [PATCH] Bugfix, oprava kompatibility OIDC --- .gitlab-ci.yml | 4 ++-- VERSION | 2 +- lib/PZ/Controller/Shortcut.pm | 2 +- lib/PZ/Helpers/OIDC.pm | 3 ++- 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index f0f6f23..10d3766 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,10 +1,10 @@ -image: docker:24 +image: docker:latest variables: DOCKER_TLS_CERTDIR: "/certs" services: - - docker:24-dind + - docker:dind before_script: - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY diff --git a/VERSION b/VERSION index 1817afe..9f8d8a9 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2.8.2 +2.8.3 diff --git a/lib/PZ/Controller/Shortcut.pm b/lib/PZ/Controller/Shortcut.pm index 316fcec..e71d6ab 100644 --- a/lib/PZ/Controller/Shortcut.pm +++ b/lib/PZ/Controller/Shortcut.pm @@ -68,7 +68,7 @@ sub create ($c) { my $shortcut = $user->add_to_shortcuts({ url => $url, - title => $title, + title => ($title || ''), shortcut => ($custom || $c->schema->resultset('Shortcut')->generate()) }); diff --git a/lib/PZ/Helpers/OIDC.pm b/lib/PZ/Helpers/OIDC.pm index 66d8a4c..90ba8eb 100644 --- a/lib/PZ/Helpers/OIDC.pm +++ b/lib/PZ/Helpers/OIDC.pm @@ -23,8 +23,9 @@ sub register { my $res = $tx->result; if ($res->is_success) { + my $key = join "\n", unpack("(A64)*", $res->json->{public_key}); $jwt = Mojo::JWT->new( - public => sprintf( KEY_FORMAT, $res->json->{public_key} ) + public => sprintf( KEY_FORMAT, $key ) ); } -- GitLab