From f471cae50bb87142a953b5a036e53bf17d38c093 Mon Sep 17 00:00:00 2001 From: Jack Tysoe <91137069+tysoekong@users.noreply.github.com> Date: Wed, 24 Jan 2024 23:07:12 +0000 Subject: [PATCH] Update kong/plugins/ai-prompt-guard/schema.lua Co-authored-by: Vinicius Mignot --- kong/plugins/ai-prompt-guard/schema.lua | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/kong/plugins/ai-prompt-guard/schema.lua b/kong/plugins/ai-prompt-guard/schema.lua index 16213193e53..da4dd49eebc 100644 --- a/kong/plugins/ai-prompt-guard/schema.lua +++ b/kong/plugins/ai-prompt-guard/schema.lua @@ -39,23 +39,6 @@ return { entity_checks = { { at_least_one_of = { "config.allow_patterns", "config.deny_patterns" }, - -- custom_entity_check = { - -- field_sources = { "config" }, - -- fn = function(entity) - -- local config = entity.config - - -- if config then - -- local allow_patterns_set = (config.allow_patterns) and (#config.allow_patterns > 0) - -- local deny_patterns_set = (config.deny_patterns) and (#config.deny_patterns > 0) - - -- if (not allow_patterns_set) and (not deny_patterns_set) then - -- return nil, "must set one item in either [allow_patterns] or [deny_patterns]" - -- end - -- end - - -- return true - -- end - -- } } } }