Code Duplication    Length = 5-5 lines in 2 locations

app/Repository/Project/Issue/Updater.php 1 location

@@ 378-382 (lines=5) @@
375
        $data['removed_tags'][] = $oldTag->toShortArray();
376
377
        // Add new tag
378
        if (!$this->model->tags->contains($newTag)) {
379
            $this->model->tags()->attach($newTag);
380
381
            $data['added_tags'][] = $newTag->toShortArray();
382
        }
383
384
        if (!empty($data)) {
385
            // Add this change to messages queue

app/Repository/Traits/Project/Issue/CrudTagTrait.php 1 location

@@ 160-164 (lines=5) @@
157
        $data['removed_tags'][] = $oldTag->toShortArray();
158
159
        // Add new tag
160
        if (!$this->tags->contains($newTag)) {
161
            $this->tags()->attach($newTag);
162
163
            $data['added_tags'][] = $newTag->toShortArray();
164
        }
165
166
        if (!empty($data)) {
167
            // Add this change to messages queue