Code Duplication    Length = 11-11 lines in 2 locations

src/Models/DirectEliminationFight.php 1 location

@@ 7-17 (lines=11) @@
4
5
class DirectEliminationFight extends Fight
6
{
7
    public function __construct(Fight $fight = null)
8
    {
9
        parent::__construct();
10
        if ($fight!=null){
11
            $this->id= $fight->id;
12
            $this->short_id= $fight->short_id;
13
            $this->fighters_group_id= $fight->fighters_group_id;
14
            $this->c1= $fight->c1;
15
            $this->c2= $fight->c2;
16
        }
17
    }
18
    /**
19
     * @param Championship $championship
20
     */

src/Models/PreliminaryFight.php 1 location

@@ 10-20 (lines=11) @@
7
class PreliminaryFight extends Fight
8
{
9
10
    public function __construct(Fight $fight = null)
11
    {
12
        parent::__construct();
13
        if ($fight!=null){
14
            $this->id= $fight->id;
15
            $this->short_id= $fight->short_id;
16
            $this->fighters_group_id= $fight->fighters_group_id;
17
            $this->c1= $fight->c1;
18
            $this->c2= $fight->c2;
19
        }
20
    }
21
22
    /**
23
     * Save a Fight.