Code Duplication    Length = 3-3 lines in 2 locations

src/Repository.php 2 locations

@@ 292-294 (lines=3) @@
289
            unset($this->persisted[$key]);
290
291
            $pk = [];
292
            foreach ($this->space->getPrimaryIndex()['parts'] as $part) {
293
                $pk[] = $this->original[$key][$part[0]];
294
            }
295
296
            foreach ($this->getMapper()->getPlugins() as $plugin) {
297
                $plugin->beforeRemove($instance, $this->space);
@@ 362-364 (lines=3) @@
359
            }
360
361
            $pk = [];
362
            foreach ($this->space->getPrimaryIndex()['parts'] as $part) {
363
                $pk[] = $this->original[$key][$part[0]];
364
            }
365
366
            $client->getSpace($this->space->getId())->update($pk, $operations);
367
            $this->original[$key] = $tuple;