Skip to content

Commit

Permalink
phpstan: fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
protitude committed Jul 5, 2023
1 parent fa629d5 commit d27a773
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion oit_dev.install
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ function oit_dev_install() {
$this_user->save();
}
// Pull in archived news to add to add to robots.txt.
new AddToRobots();
\Drupal::service('oit_dev.robots');
}

/**
Expand Down
1 change: 1 addition & 0 deletions src/Plugin/AddToRobots.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ public function __construct(EntityTypeManagerInterface $entity_type_manager) {
$node = $this->entityTypeManager->getStorage('node');
$query = $node->getQuery();
$query->condition('field_news_archive', 3);
$query->accessCheck(FALSE);
$news_results = $query->execute();
$news_archive_string = "# Paths OIT\n";
$news_archive_string .= "Disallow: /taxonomy/term/*\n";
Expand Down

0 comments on commit d27a773

Please sign in to comment.