From 3d2a78e962e7fc77febf0ea6774b7b4e0fef0878 Mon Sep 17 00:00:00 2001 From: Joe Nelson Date: Thu, 5 Nov 2015 17:18:22 -0800 Subject: [PATCH] Encode JWT when proc return types end in jwt_claims Fixes it when the jwt_claims type is defined in a non-default schema --- src/PostgREST/PgStructure.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PostgREST/PgStructure.hs b/src/PostgREST/PgStructure.hs index d7e1710db..70d804f7d 100644 --- a/src/PostgREST/PgStructure.hs +++ b/src/PostgREST/PgStructure.hs @@ -45,7 +45,7 @@ doesProcReturnJWT = doesProc [H.stmt| ON pronamespace = n.oid WHERE nspname = ? AND proname = ? - AND pg_catalog.pg_get_function_result(p.oid) = 'jwt_claims' + AND pg_catalog.pg_get_function_result(p.oid) like '%jwt_claims' |] tableFromRow :: (Text, Text, Bool, Maybe Text) -> Table