Code Duplication    Length = 8-9 lines in 2 locations

src/Http/Controllers/AdminController.php 2 locations

@@ 97-105 (lines=9) @@
94
        return response()->json(['message' => 'ok']);
95
    }
96
97
    public function delete(ComponentInterface $component, $id)
98
    {
99
        if (!$component->isDelete()) {
100
            throw new AuthorizationException();
101
        }
102
103
        $component->delete($id);
104
        return response()->json(['message' => 'ok']);
105
    }
106
107
    public function forceDelete(ComponentInterface $component, $id)
108
    {
@@ 126-133 (lines=8) @@
123
        return response()->json(['message' => 'ok']);
124
    }
125
126
    public function reorder(ComponentInterface $component)
127
    {
128
        if (!$component->isEdit()) {
129
            throw new AuthorizationException();
130
        }
131
132
        return response()->json(['message' => 'ok']);
133
    }
134
}
135