Skip to content

Commit

Permalink
Add accessCheck to entity query
Browse files Browse the repository at this point in the history
Updates #8
  • Loading branch information
inghamn committed Nov 7, 2024
1 parent 8b9d53b commit 5531882
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Controller/ArchiveController.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* @copyright 2017-2019 City of Bloomington, Indiana
* @copyright 2017-2024 City of Bloomington, Indiana
* @license http://www.gnu.org/licenses/agpl.txt GNU/AGPL, see LICENSE
*/
namespace Drupal\archive\Controller;
Expand Down Expand Up @@ -45,6 +45,7 @@ public function archive($type, $year, $month, $day)

$manager = \Drupal::entityTypeManager();
$query = \Drupal::entityQuery('node')
->accessCheck(true),
->condition('type', $type)
->condition('created', $start->format('U'), '>=')
->condition('created', $end ->format('U'), '<')
Expand Down

0 comments on commit 5531882

Please sign in to comment.