Code Duplication    Length = 5-5 lines in 5 locations

system/Inji/Model.php 5 locations

@@ 803-807 (lines=5) @@
800
            return false;
801
        }
802
        $classPath = explode('\\', get_called_class());
803
        if (!empty(static::$storage['options']['share'])) {
804
            $moduleConfig = Config::share($classPath[0]);
805
        } else {
806
            $moduleConfig = Config::module($classPath[0], strpos(static::$storage['type'], 'system') !== false);
807
        }
808
        $appType = App::$cur->type;
809
        if (!empty($moduleConfig['storage']['appTypeSplit'])) {
810
            if (!empty($options['appType'])) {
@@ 843-847 (lines=5) @@
840
    public static function getListFromModuleStorage($options = [])
841
    {
842
        $classPath = explode('\\', get_called_class());
843
        if (!empty(static::$storage['options']['share'])) {
844
            $moduleConfig = Config::share($classPath[0]);
845
        } else {
846
            $moduleConfig = Config::module($classPath[0], strpos(static::$storage['type'], 'system') !== false);
847
        }
848
        if (!empty($moduleConfig['storage']['appTypeSplit'])) {
849
            if (empty($options['appType'])) {
850
                $appType = App::$cur->type;
@@ 910-914 (lines=5) @@
907
        } else {
908
            $appType = $options['appType'];
909
        }
910
        if (!empty(static::$storage['options']['share'])) {
911
            $moduleConfig = Config::share($classPath[0]);
912
        } else {
913
            $moduleConfig = Config::module($classPath[0], strpos(static::$storage['type'], 'system') !== false);
914
        }
915
        if (!empty($moduleConfig['storage'][$appType][$classPath[1]])) {
916
            $items = $moduleConfig['storage'][$appType][$classPath[1]];
917
            if (empty($options['where'])) {
@@ 1125-1129 (lines=5) @@
1122
        $appType = '';
1123
        $classPath = explode('\\', get_called_class());
1124
1125
        if (!empty(static::$storage['options']['share'])) {
1126
            $moduleConfig = Config::share($classPath[0]);
1127
        } else {
1128
            $moduleConfig = Config::module($classPath[0], strpos(static::$storage['type'], 'system') !== false);
1129
        }
1130
1131
        if (!empty($moduleConfig['storage']['appTypeSplit'])) {
1132
            if (empty($options['appType'])) {
@@ 1328-1332 (lines=5) @@
1325
        $id = $this->pk();
1326
        $appType = '';
1327
        $classPath = explode('\\', get_called_class());
1328
        if (!empty(static::$storage['options']['share'])) {
1329
            $moduleConfig = Config::share($classPath[0]);
1330
        } else {
1331
            $moduleConfig = Config::module($classPath[0], strpos(static::$storage['type'], 'system') !== false);
1332
        }
1333
1334
        if (!empty($moduleConfig['storage']['appTypeSplit'])) {
1335
            if (empty($options['appType'])) {