#include "s_conf.h"
#include "snomask.h"
#include "numeric.h"
+#include "s_newconf.h"
static const char restrict_desc[] = "Restricts channel creation to IRC operators";
-static void h_can_create_channel_authenticated(hook_data_client_approval *);
+static void h_can_create_channel_authenticated(void *);
mapi_hfn_list_av1 restrict_hfnlist[] = {
- { "can_create_channel", (hookfn) h_can_create_channel_authenticated },
+ { "can_create_channel", h_can_create_channel_authenticated },
{ NULL, NULL }
};
DECLARE_MODULE_AV2(createoperonly, NULL, NULL, NULL, NULL, restrict_hfnlist, NULL, NULL, restrict_desc);
static void
-h_can_create_channel_authenticated(hook_data_client_approval *data)
+h_can_create_channel_authenticated(void *data_)
{
+ hook_data_client_approval *data = data_;
struct Client *source_p = data->client;
- if (!IsOper(source_p))
+ if (!IsOperGeneral(source_p))
{
sendto_one_notice(source_p, ":*** Channel creation is restricted to network staff only.");
data->approved = ERR_NEEDREGGEDNICK;