mirror of
https://github.com/tiennm99/coolify.git
synced 2026-04-18 03:20:26 +00:00
fix: ensure authorization checks are in place for viewing and updating the application
This commit is contained in:
@@ -26,7 +26,8 @@ class EditDomain extends Component
|
||||
|
||||
public function mount()
|
||||
{
|
||||
$this->application = ServiceApplication::find($this->applicationId);
|
||||
$this->application = ServiceApplication::query()->findOrFail($this->applicationId);
|
||||
$this->authorize('view', $this->application);
|
||||
$this->syncData(false);
|
||||
}
|
||||
|
||||
@@ -49,6 +50,7 @@ class EditDomain extends Component
|
||||
public function submit()
|
||||
{
|
||||
try {
|
||||
$this->authorize('update', $this->application);
|
||||
$this->fqdn = str($this->fqdn)->replaceEnd(',', '')->trim()->toString();
|
||||
$this->fqdn = str($this->fqdn)->replaceStart(',', '')->trim()->toString();
|
||||
$domains = str($this->fqdn)->trim()->explode(',')->map(function ($domain) {
|
||||
|
||||
Reference in New Issue
Block a user