Code Duplication    Length = 7-7 lines in 2 locations

system/Inji/Model.php 2 locations

@@ 437-443 (lines=7) @@
434
                        case 'array':
435
                            $oldValueText = isset($class::$cols[$colName]['sourceArray'][$oldValue]) ? $class::$cols[$colName]['sourceArray'][$oldValue] : $oldValue;
436
                            break;
437
                        case 'relation':
438
                            $relation = $class::getRelation($class::$cols[$colName]['relation']);
439
                            $relModel = $relation['model'];
440
                            $rel = $relModel::get($oldValue);
441
                            if ($rel) {
442
                                $oldValueText = $rel->name();
443
                            }
444
                    }
445
                }
446
                $newValueText = $this->$colName;
@@ 452-458 (lines=7) @@
449
                        case 'array':
450
                            $newValueText = isset($class::$cols[$colName]['sourceArray'][$this->$colName]) ? $class::$cols[$colName]['sourceArray'][$this->$colName] : $this->$colName;
451
                            break;
452
                        case 'relation':
453
                            $relation = $class::getRelation($class::$cols[$colName]['relation']);
454
                            $relModel = $relation['model'];
455
                            $rel = $relModel::get($this->$colName);
456
                            if ($rel) {
457
                                $newValueText = $rel->name();
458
                            }
459
                    }
460
                }
461
                if (strlen($oldValueText) + strlen($newValueText) < 200) {