mirror of
https://github.com/farmOS/farmOS.git
synced 2024-02-23 11:37:38 +01:00
Remove un-needed phpstan ignores.
See https://github.com/mglaman/phpstan-drupal/issues/474
This commit is contained in:
parent
391acb6511
commit
69f12631e2
|
@ -151,8 +151,6 @@ class FarmMetricsBlock extends BlockBase implements ContainerFactoryPluginInterf
|
|||
$query->condition('status', 'active');
|
||||
}
|
||||
|
||||
// @todo https://github.com/mglaman/phpstan-drupal/issues/474
|
||||
// @phpstan-ignore-next-line
|
||||
$count = $query->count()->execute();
|
||||
$route_name = "view.farm_$entity_type.page_type";
|
||||
$metrics[] = Link::createFromRoute($bundle_info['label'] . ': ' . $count, $route_name, ['arg_0' => $bundle], ['attributes' => ['class' => ['metric', 'button']]])->toString();
|
||||
|
|
|
@ -63,8 +63,6 @@ class FarmAssetChildrenViewsAccessCheck implements AccessInterface {
|
|||
|
||||
// Run a count query to see if there are any assets that reference this
|
||||
// asset as a parent.
|
||||
// @todo https://github.com/mglaman/phpstan-drupal/issues/474
|
||||
// @phpstan-ignore-next-line
|
||||
$count = $this->assetStorage->getAggregateQuery()
|
||||
->accessCheck(TRUE)
|
||||
->condition('parent.entity.id', $asset_id)
|
||||
|
|
|
@ -62,8 +62,6 @@ class FarmAssetLogViewsAccessCheck implements AccessInterface {
|
|||
$query->condition($reference_condition);
|
||||
|
||||
// Determine access based on the log count.
|
||||
// @todo https://github.com/mglaman/phpstan-drupal/issues/474
|
||||
// @phpstan-ignore-next-line
|
||||
$count = $query->execute();
|
||||
$access = AccessResult::allowedIf($count > 0);
|
||||
|
||||
|
|
|
@ -66,8 +66,6 @@ class UniqueBirthLogConstraintValidator extends ConstraintValidator implements C
|
|||
|
||||
// Query the number of birth logs that reference the asset.
|
||||
// We do not check access to ensure that all matching logs are found.
|
||||
// @todo https://github.com/mglaman/phpstan-drupal/issues/474
|
||||
// @phpstan-ignore-next-line
|
||||
$count = $this->entityTypeManager->getStorage('log')->getAggregateQuery()
|
||||
->accessCheck(FALSE)
|
||||
->condition('type', 'birth')
|
||||
|
|
Loading…
Reference in a new issue