diff --git a/app/Http/Controllers/Api/ConsumablesController.php b/app/Http/Controllers/Api/ConsumablesController.php index 7a41c9ec41..3c1184d38b 100644 --- a/app/Http/Controllers/Api/ConsumablesController.php +++ b/app/Http/Controllers/Api/ConsumablesController.php @@ -173,7 +173,7 @@ class ConsumablesController extends Controller if (!Company::isCurrentUserHasAccess($consumable)) { return ['total' => 0, 'rows' => []]; } - $this->authorize('view', Component::class); + $this->authorize('view', Consumable::class); $rows = array(); foreach ($consumable->consumableAssignments as $consumable_assignment) {