Skip to content
This repository was archived by the owner on Jul 24, 2023. It is now read-only.

Commit 2725530

Browse files
committed
Only retrieve the configured model once
1 parent 6dbbcb9 commit 2725530

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Commands/Console/Import.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,11 +92,13 @@ public function import(array $users = []) : int
9292

9393
$this->output->progressStart(count($users));
9494

95+
$model = $this->model();
96+
9597
foreach ($users as $user) {
9698
try {
9799
// Import the user and retrieve it's model.
98100
$model = Bus::dispatch(
99-
new ImportUser($user, $this->model())
101+
new ImportUser($user, $model)
100102
);
101103

102104
// Set the users password.

0 commit comments

Comments
 (0)