Code Duplication    Length = 13-13 lines in 2 locations

src/Http/Controllers/LaravelOpdController.php 1 location

@@ 85-97 (lines=13) @@
82
        return redirect()->back();
83
    }
84
85
    public function storeChild(Request $request)
86
    {
87
        $check_root = LaravelOpdModel::where('id',$request->root);
88
                          
89
            $check_root->first()->children()->create([
90
                'kunker' => $request->c_kunker,
91
                'kunker_simral' => '',
92
                'name' => $request->c_name,
93
                'levelunker' => $request->c_levelunker,
94
            ]);        
95
96
        return redirect()->back();
97
    }
98
}
99

src/LaravelOpd.php 1 location

@@ 94-106 (lines=13) @@
91
        return redirect()->back();
92
    }
93
94
    public function storeChild($request = array())
95
    {
96
        $check_root = LaravelOpdModel::where('id',$request->root);
97
                          
98
            $check_root->first()->children()->create([
99
                'kunker' => $request->c_kunker,
100
                'kunker_simral' => '',
101
                'name' => $request->c_name,
102
                'levelunker' => $request->c_levelunker,
103
            ]);        
104
105
        return redirect()->back();
106
    }
107
}
108