This class seems to be duplicated in your project.
Duplicated code is one of the most pungent code smells. If you need to duplicate
the same code in three or more different places, we strongly encourage you to
look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.
Loading history...
15
{
16
17
use DispatchesJobs;
18
19
/**
20
* The field instance.
21
*
22
* @var FieldInterface
23
*/
24
protected $field;
25
26
/**
27
* Create a new ChangeFieldAssignments instance.
28
*
29
* @param FieldInterface $field
30
*/
31
public function __construct(FieldInterface $field)
32
{
33
$this->field = $field;
34
}
35
36
/**
37
* Handle the command.
38
*/
39
public function handle()
40
{
41
foreach ($this->field->getAssignments() as $assignment) {
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.