diff --git a/src/LoftDataGrids.php b/src/LoftDataGrids.php
index 43017fa..6130d1d 100644
--- a/src/LoftDataGrids.php
+++ b/src/LoftDataGrids.php
@@ -96,7 +96,7 @@
         // Add in the access flag for the current user.
         $user = \Drupal::currentUser();
         array_walk($exporters, function (&$info) use ($user) {
-            $perm = 'loft_data_grids:' . $info['class'];
+            $perm = 'loft_data_grids:' . $info['id'];
             $info['access'] = $user->hasPermission($perm);
         });
 
