mirror of
https://github.com/flarum/framework.git
synced 2025-02-21 04:31:57 +08:00
Simplify variable assignment using null coalescing operator (#4000)
This commit is contained in:
parent
f3c8921b09
commit
19196c219c
@ -36,7 +36,7 @@ class ComposerAdapter
|
||||
{
|
||||
$this->application->resetComposer();
|
||||
|
||||
$this->output = $this->output ?? new BufferedOutput();
|
||||
$this->output ??= new BufferedOutput();
|
||||
|
||||
// This hack is necessary so that relative path repositories are resolved properly.
|
||||
$currDir = getcwd();
|
||||
|
@ -123,7 +123,7 @@ class EnableBundledExtensions implements Step
|
||||
|
||||
private function getMigrator(): Migrator
|
||||
{
|
||||
return $this->migrator = $this->migrator ?? new Migrator(
|
||||
return $this->migrator ??= new Migrator(
|
||||
new DatabaseMigrationRepository($this->database, 'migrations'),
|
||||
$this->database,
|
||||
new \Illuminate\Filesystem\Filesystem
|
||||
|
Loading…
x
Reference in New Issue
Block a user