Update egg import/update logic to all use the same pathwaus
This commit is contained in:
parent
6554164252
commit
cca0010a00
12 changed files with 271 additions and 334 deletions
22
app/Observers/EggVariableObserver.php
Normal file
22
app/Observers/EggVariableObserver.php
Normal file
|
@ -0,0 +1,22 @@
|
|||
<?php
|
||||
|
||||
namespace Pterodactyl\Observers;
|
||||
|
||||
use Pterodactyl\Models\EggVariable;
|
||||
|
||||
class EggVariableObserver
|
||||
{
|
||||
public function creating(EggVariable $variable): void
|
||||
{
|
||||
if ($variable->field_type) {
|
||||
unset($variable->field_type);
|
||||
}
|
||||
}
|
||||
|
||||
public function updating(EggVariable $variable): void
|
||||
{
|
||||
if ($variable->field_type) {
|
||||
unset($variable->field_type);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue