| @@ -64,13 +64,16 @@ | ||
| 64 | 64 | ]); |
| 65 | 65 | } |
| 66 | 66 | |
| 67 | 67 | /** |
| 68 | - * Check user permissions | |
| 68 | + * Sample-data import / cleanup — gated on the settings cap. | |
| 69 | + * Installing or removing sample content is a one-time setup | |
| 70 | + * task with the same risk profile as other settings changes. | |
| 71 | + * WP admins pass via the Team module's admin-fallback filter. | |
| 69 | 72 | */ |
| 70 | 73 | public function check_permissions() |
| 71 | 74 | { |
| 72 | - return current_user_can('manage_options'); | |
| 75 | + return current_user_can('yatra_manage_settings'); | |
| 73 | 76 | } |
| 74 | 77 | |
| 75 | 78 | /** |
| 76 | 79 | * Handle import actions from admin forms |