From 3bc3b5cdc6edb669abf04a88c6abd405a6fb86e2 Mon Sep 17 00:00:00 2001 From: Robert Schuh Date: Wed, 28 Jun 2023 12:07:49 +0200 Subject: [PATCH] fix logic to allow multiple claim values as OR --- main.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.go b/main.go index 8390ff1..527b8d6 100644 --- a/main.go +++ b/main.go @@ -262,10 +262,10 @@ func (s *server) checkClaim( claim := e.(string) actualClaims[i] = claim } - for _, validPattern := range validPatterns { + for _, actualClaim := range actualClaims { passedValidation = false out: - for _, actualClaim := range actualClaims { + for _, validPattern := range validPatterns { if contains([]string{validPattern}, actualClaim, isRegExp) { passedValidation = true break out