Code Duplication    Length = 8-8 lines in 2 locations

src/Models/ElementModel.php 1 location

@@ 130-137 (lines=8) @@
127
     * @return static|bool
128
     * @throws ExceptionFromBitrix
129
     */
130
    public static function create($fields)
131
    {
132
        if (!isset($fields['IBLOCK_ID'])) {
133
            $fields['IBLOCK_ID'] = static::iblockId();
134
        }
135
136
        return static::internalCreate($fields);
137
    }
138
139
    public static function internalDirectCreate($bxObject, $fields)
140
    {

src/Models/SectionModel.php 1 location

@@ 124-131 (lines=8) @@
121
     *
122
     * @return static|bool
123
     */
124
    public static function create($fields)
125
    {
126
        if (!isset($fields['IBLOCK_ID'])) {
127
            $fields['IBLOCK_ID'] = static::iblockId();
128
        }
129
130
        return static::internalCreate($fields);
131
    }
132
133
    /**
134
     * Get IDs of direct children of the section.