Skip to content
Code-Schnipsel Gruppen Projekte
Commit 23c57d4f erstellt von Patrick Müller's avatar Patrick Müller
Dateien durchsuchen

fix: groupId must not be necessarily int; error on wrong field type

Übergeordneter 7bd83865
No related branches found
No related tags found
1 Merge Request!9fix: groupId must not be necessarily int; error on wrong field type
Pipeline #12024 mit Warnungen bestanden mit Phase
in 10 Sekunden
......@@ -186,6 +186,11 @@ protected static function createProductFields()
QUI\System\Log::addError(self::class . ' :: createProductFields');
QUI\System\Log::writeException($Exception);
}
} elseif (!($MembershipField instanceof MembershipField)) {
QUI\System\Log::addError(
'quiqqer/memberships :: Cannot create memership field because product field with ID ' .
$MembershipField->getId() . ' is not a membership field.'
);
}
// Membership flag field (create new one is not configured)
......
......@@ -66,7 +66,7 @@ public function createChild($data = []): QUI\CRUD\Child
foreach ($groupIds as $groupId) {
// check if group exist by getting them
$Groups->get((int)$groupId);
$Groups->get($groupId);
}
$data['groupIds'] = ',' . implode(',', $groupIds) . ',';
......
0% oder .
You are about to add 0 people to the discussion. Proceed with caution.
Bearbeitung dieser Nachricht zuerst beenden!
Bitte registrieren oder zum Kommentieren