diff --git a/src/class-admin.php b/src/class-admin.php index cb49cf00..1c259b40 100644 --- a/src/class-admin.php +++ b/src/class-admin.php @@ -44,6 +44,10 @@ public function maybe_load_standalone(): void return; } + if (!current_user_can('view_koko_analytics')) { + return; + } + $this->register_scripts(); require KOKO_ANALYTICS_PLUGIN_DIR . '/views/standalone.php'; exit;