From 52a30cb1d3aa7ad6999afe53c8517fdb14badc91 Mon Sep 17 00:00:00 2001 From: Matthieu Leproux Date: Wed, 24 Nov 2021 11:14:50 +0100 Subject: [PATCH] (cp 0ad1d2894) fixes #1569 No more infinite spin when unseting default groups --- include/ws_functions/pwg.groups.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/ws_functions/pwg.groups.php b/include/ws_functions/pwg.groups.php index 973a327e1..3997fee4d 100644 --- a/include/ws_functions/pwg.groups.php +++ b/include/ws_functions/pwg.groups.php @@ -131,7 +131,7 @@ function ws_groups_setInfo($params, &$service) return new PwgError(403, 'Invalid security token'); } - if (strlen(str_replace( " ", "", $params['name'])) == 0) { + if (isset($params['name']) && strlen(str_replace( " ", "", $params['name'])) == 0) { return new PwgError(WS_ERR_INVALID_PARAM, 'Name field must not be empty'); }