Code Duplication    Length = 9-10 lines in 2 locations

src/Infrastructure/DBAL/DbalShiftMapper.php 2 locations

@@ 130-138 (lines=9) @@
127
        return $this->loadAll($statement);
128
    }
129
130
    public function findShiftsInTimePeriod(DateTimeInterface $start, DateTimeInterface $end)
131
    {
132
        $statement = $this->db->prepare(self::findInTimePeriodStatement());
133
        $statement->bindValue(":start", $start, Type::DATETIME);
134
        $statement->bindValue(":end", $end, Type::DATETIME);
135
        $statement->execute();
136
137
        return $this->loadAll($statement);
138
    }
139
140
    public function findShiftsInTimePeriodByEmployeeId(DateTimeInterface $start, DateTimeInterface $end, $employeeId)
141
    {
@@ 140-149 (lines=10) @@
137
        return $this->loadAll($statement);
138
    }
139
140
    public function findShiftsInTimePeriodByEmployeeId(DateTimeInterface $start, DateTimeInterface $end, $employeeId)
141
    {
142
        $statement = $this->db->prepare(self::findInTimePeriodByEmployeeIdStatement());
143
        $statement->bindValue(":start", $start, Type::DATETIME);
144
        $statement->bindValue(":end", $end, Type::DATETIME);
145
        $statement->bindValue(":employee_id", $employeeId, \PDO::PARAM_INT);
146
        $statement->execute();
147
148
        return $this->loadAll($statement);
149
    }
150
151
    protected function doLoad($id, array $resultSet)
152
    {