Revert "rector: arrrrr"

This reverts commit 16c0cd10d8.
This commit is contained in:
Andras Bacsai
2025-01-07 15:31:43 +01:00
parent da07b4fdcf
commit 1fe4dd722b
349 changed files with 3689 additions and 4184 deletions

View File

@@ -4,7 +4,6 @@ namespace App\Livewire\Project\Shared\EnvironmentVariable;
use App\Models\EnvironmentVariable as ModelsEnvironmentVariable;
use App\Models\SharedEnvironmentVariable;
use Exception;
use Livewire\Component;
class Show extends Component
@@ -61,7 +60,7 @@ class Show extends Component
public function mount()
{
$this->syncData();
if ($this->env->getMorphClass() === SharedEnvironmentVariable::class) {
if ($this->env->getMorphClass() === \App\Models\SharedEnvironmentVariable::class) {
$this->isSharedVariable = true;
}
$this->parameters = get_route_parameters();
@@ -117,7 +116,7 @@ class Show extends Component
public function serialize()
{
data_forget($this->env, 'real_value');
if ($this->env->getMorphClass() === SharedEnvironmentVariable::class) {
if ($this->env->getMorphClass() === \App\Models\SharedEnvironmentVariable::class) {
data_forget($this->env, 'is_build_time');
}
}
@@ -157,7 +156,7 @@ class Show extends Component
$this->value = $oldValue;
$this->dispatch('error', 'Required environment variable cannot be empty.');
return null;
return;
}
$this->serialize();
@@ -169,11 +168,9 @@ class Show extends Component
$this->syncData(true);
$this->dispatch('success', 'Environment variable updated.');
$this->dispatch('envsUpdated');
} catch (Exception $e) {
} catch (\Exception $e) {
return handleError($e);
}
return null;
}
public function delete()
@@ -182,10 +179,8 @@ class Show extends Component
$this->env->delete();
$this->dispatch('environmentVariableDeleted');
$this->dispatch('success', 'Environment variable deleted successfully.');
} catch (Exception $e) {
} catch (\Exception $e) {
return handleError($e);
}
return null;
}
}