From 93c3b359ea720542056b075027c50fd18da87285 Mon Sep 17 00:00:00 2001 From: Micha Ober Date: Wed, 8 Nov 2023 23:24:37 +0100 Subject: [PATCH] Check if `curl` extension is available when installing --- ext.php | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 ext.php diff --git a/ext.php b/ext.php new file mode 100644 index 0000000..63c8480 --- /dev/null +++ b/ext.php @@ -0,0 +1,23 @@ +container->get('language'); + $language->add_lang('acp_discord_notifications', 'mober/discordnotifications'); + + $curl_available = extension_loaded('curl'); + if (!$curl_available) + { + return $language->lang('DN_MISSING_CURL'); + } + + return true; + } +}