Fix FLEXIAPI-341 Allow realm to be empty when creating a Space

This commit is contained in:
Timothée Jaussoin 2025-07-01 12:04:49 +02:00
parent f712755b79
commit c8e587db01
4 changed files with 5 additions and 3 deletions

View file

@ -56,6 +56,7 @@ v2.0
- Fix FLEXIAPI-337 Generate the provisioning URLs based on the user space
- Fix FLEXIAPI-326 Rework email templates and translations
- Fix FLEXIAPI-340 Fix the space resolution when getting the realm on Accounts
- Fix FLEXIAPI-341 Allow realm to be empty when creating a Space
v1.6
----

View file

@ -1,6 +1,5 @@
# Releases
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/).

View file

@ -67,7 +67,7 @@ class SpaceController extends Controller
'domain' => ['required', 'unique:spaces', new Domain()],
'host' => 'nullable|regex:/'. Space::HOST_REGEX . '/',
'full_host' => ['required', 'unique:spaces,host', new Domain()],
'account_realm' => [new Domain()],
'account_realm' => ['nullable', new Domain()],
]);
$space = new Space();

View file

@ -42,7 +42,8 @@ class SpaceController extends Controller
'host' => ['required', 'unique:spaces', new Domain()],
'max_accounts' => 'nullable|integer',
'expire_at' => 'nullable|date|after_or_equal:today',
'custom_provisioning_entries' => ['nullable', new Ini(Space::FORBIDDEN_KEYS)]
'custom_provisioning_entries' => ['nullable', new Ini(Space::FORBIDDEN_KEYS)],
'account_realm' => ['nullable', new Domain()],
]);
$space = new Space;
@ -105,6 +106,7 @@ class SpaceController extends Controller
'max_account' => 'required|integer',
'max_accounts' => 'required|integer',
'expire_at' => 'nullable|date|after_or_equal:today',
'account_realm' => ['nullable', new Domain()],
'custom_provisioning_entries' => ['nullable', new Ini(Space::FORBIDDEN_KEYS)],
'custom_provisioning_overwrite_all' => 'required|boolean',