first commit
Some checks failed
Build / run (push) Has been cancelled

This commit is contained in:
maher
2025-10-29 11:42:25 +01:00
commit 703f50a09d
4595 changed files with 385164 additions and 0 deletions

26
common/Core/BaseTrustHosts.php Executable file
View File

@@ -0,0 +1,26 @@
<?php
namespace Common\Core;
use Common\Domains\CustomDomainController;
use Illuminate\Http\Middleware\TrustHosts as Middleware;
class BaseTrustHosts extends Middleware
{
public function hosts(): array
{
return [
$this->allSubdomainsOfApplicationUrl(),
];
}
protected function shouldSpecifyTrustedHosts(): bool
{
// allow custom domain validation
if (request()->path() === CustomDomainController::VALIDATE_CUSTOM_DOMAIN_PATH) {
return false;
} else {
return parent::shouldSpecifyTrustedHosts();
}
}
}