Code Duplication    Length = 11-11 lines in 2 locations

source/Spiral/Database/Schemas/StateComparator.php 2 locations

@@ 199-209 (lines=11) @@
196
    /**
197
     * @return AbstractReference[]
198
     */
199
    public function addedForeigns(): array
200
    {
201
        $difference = [];
202
        foreach ($this->current->getForeigns() as $name => $foreign) {
203
            if (!$this->initial->knowsForeign($name)) {
204
                $difference[] = $foreign;
205
            }
206
        }
207
208
        return $difference;
209
    }
210
211
    /**
212
     * @return AbstractReference[]
@@ 214-224 (lines=11) @@
211
    /**
212
     * @return AbstractReference[]
213
     */
214
    public function droppedForeigns(): array
215
    {
216
        $difference = [];
217
        foreach ($this->initial->getForeigns() as $name => $foreign) {
218
            if (!$this->current->knowsForeign($name)) {
219
                $difference[] = $foreign;
220
            }
221
        }
222
223
        return $difference;
224
    }
225
226
    /**
227
     * Returns array where each value contain current and initial element state.