Skip to content

Commit 995c09d

Browse files
authored
Refactor globals export (#358)
1 parent f0c69a3 commit 995c09d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/Commands/ExportGlobals.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -73,15 +73,15 @@ private function exportGlobals()
7373
$this->withProgressBar($sets, function ($model) use ($variables) {
7474
$global = GlobalSetFacade::make()
7575
->handle($model->handle)
76-
->title($model->title)
77-
->save();
76+
->title($model->title);
7877

7978
foreach ($variables->where('handle', $model->handle) as $localization) {
8079
$global->makeLocalization($localization->locale)
8180
->data($localization->data)
82-
->origin($localization->origin ?? null)
83-
->save();
81+
->origin($localization->origin ?? null);
8482
}
83+
84+
$global->save();
8585
});
8686

8787
$this->newLine();

0 commit comments

Comments
 (0)