From 5b6074c38a2784a0e309bdd69ff86e4858a4ffd0 Mon Sep 17 00:00:00 2001 From: "claude[bot]" <41898282+claude[bot]@users.noreply.github.com> Date: Fri, 2 Jan 2026 11:16:52 +0000 Subject: [PATCH] Move FQDN trim before validation in submit() method MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The trim operation was happening after validation, which meant whitespace was counted toward the max:255 validation rule. Now input is normalized before validation, matching the pattern used in Application and Service components. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Andras Bacsai --- app/Livewire/Settings/Index.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/Livewire/Settings/Index.php b/app/Livewire/Settings/Index.php index 98730e1a4..14c0eec32 100644 --- a/app/Livewire/Settings/Index.php +++ b/app/Livewire/Settings/Index.php @@ -119,13 +119,14 @@ public function submit() return; } - $this->validate(); - // Trim FQDN to remove leading/trailing whitespace + // Trim FQDN to remove leading/trailing whitespace before validation if ($this->fqdn) { $this->fqdn = trim($this->fqdn); } + $this->validate(); + if ($this->settings->is_dns_validation_enabled && $this->fqdn) { if (! validateDNSEntry($this->fqdn, $this->server)) { $this->dispatch('error', "Validating DNS failed.

Make sure you have added the DNS records correctly.

{$this->fqdn}->{$this->server->ip}

Check this documentation for further help.");