Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save amcgowanca/9a2e532431d1695785ad21ed3c95a0ab to your computer and use it in GitHub Desktop.
Save amcgowanca/9a2e532431d1695785ad21ed3c95a0ab to your computer and use it in GitHub Desktop.
Acquia Lightning's Scheduler module needs to bypass access checks during CRON
diff --git a/modules/lightning_scheduler/lightning_scheduler.module b/modules/lightning_scheduler/lightning_scheduler.module
index 94a28a7..61e1532 100644
--- a/modules/lightning_scheduler/lightning_scheduler.module
+++ b/modules/lightning_scheduler/lightning_scheduler.module
@@ -74,6 +74,7 @@ function lightning_scheduler_cron() {
->getStorage($entity_type_id)
->getQuery()
->condition('scheduled_publication', $now, '<=')
+ ->accessCheck(FALSE)
->execute();
foreach ($result as $entity_id) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment