From a03142671519a8e056d4648183003655165c9abd Mon Sep 17 00:00:00 2001 From: Steve Munene Date: Tue, 3 Mar 2026 18:01:48 +0300 Subject: [PATCH] NOISSUE - Update metadata UI type to string (#422) Signed-off-by: nyagamunene --- re/postgres/init.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/re/postgres/init.go b/re/postgres/init.go index f01e63336..2420b8956 100644 --- a/re/postgres/init.go +++ b/re/postgres/init.go @@ -55,12 +55,12 @@ func Migration() *migrate.MemoryMigrationSource { Up: []string{ `UPDATE rules SET metadata = (COALESCE(metadata, '{}'::jsonb) - 'ui') || jsonb_build_object('flow', metadata->'ui') - WHERE metadata ? 'ui' AND jsonb_typeof(metadata->'ui') = 'object'`, + WHERE metadata ? 'ui' AND jsonb_typeof(metadata->'ui') = 'string'`, }, Down: []string{ `UPDATE rules SET metadata = (COALESCE(metadata, '{}'::jsonb) - 'flow') || jsonb_build_object('ui', metadata->'flow') - WHERE metadata ? 'flow' AND jsonb_typeof(metadata->'flow') = 'object'`, + WHERE metadata ? 'flow' AND jsonb_typeof(metadata->'flow') = 'string'`, }, }, },