From 872d7f482797cbfff7295f4a909743b777f6ea1c Mon Sep 17 00:00:00 2001 From: Kay Faraday Date: Sat, 4 Feb 2023 05:42:20 +0000 Subject: [PATCH] fix invalid statement error --- blockbot.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/blockbot.sql b/blockbot.sql index 6e17f8e..40db499 100644 --- a/blockbot.sql +++ b/blockbot.sql @@ -51,7 +51,7 @@ SELECT blockbot_notify( $$ LANGUAGE SQL; CREATE FUNCTION blockbot_block() RETURNS TRIGGER AS $$ BEGIN - SELECT blockbot_trigger_inner(NEW.account_id, NEW.target_account_id, false); + PERFORM * FROM blockbot_trigger_inner(NEW.account_id, NEW.target_account_id, false); RETURN NEW; END; $$ LANGUAGE plpgsql; @@ -61,7 +61,7 @@ FOR EACH ROW EXECUTE FUNCTION blockbot_block(); CREATE FUNCTION blockbot_unblock() RETURNS TRIGGER AS $$ BEGIN - SELECT blockbot_trigger_inner(OLD.account_id, OLD.target_account_id, true); + PERFORM * FROM blockbot_trigger_inner(OLD.account_id, OLD.target_account_id, true); RETURN NULL; END; $$ LANGUAGE plpgsql;