Added function 'local_webhooks_delete_record'

Signed-off-by: Valentin Popov <info@valentineus.link>
This commit is contained in:
Valentin Popov 2018-03-13 00:48:12 +04:00
parent e8b59e7b0d
commit 98e5a6470d
Signed by: Valentin Popov
GPG Key ID: 269A00ACA90A8EA3

View File

@ -199,6 +199,7 @@ function local_webhooks_delete_record($serviceid) {
global $DB;
$result = $DB->delete_records(LOCAL_WEBHOOKS_TABLE_SERVICES, array("id" => $serviceid));
local_webhooks_delete_events_for_service($serviceid);
/* Clear the plugin cache */
local_webhooks_cache_reset();