public function access(RouteMatchInterface $route_match, AccountInterface $account, $permission = NULL) {
    if (count($this->languageManager->getLanguages()) > 1) {
      if (!empty($permission)) {
        return AccessResult::allowedIfHasPermission($account, $permission);
      }
      else {
        return AccessResult::allowed();
      }
    }

    return AccessResult::forbidden();
  }
public function access(RouteMatchInterface $route_match, AccountInterface $account, $permission = NULL) {
    if (count($this->languageManager->getLanguages()) > 1) {
      if (!empty($permission)) {
        return AccessResult::allowedIfHasPermission($account, $permission);
      }
      else {
        return AccessResult::allowed();
      }
    }

    return AccessResult::forbidden();
  }
public function access ( RouteMatchInterface $ route_match , AccountInterface $ account , $ permission = NULL ) { if ( count ( $ this -> languageManager -> getLanguages ( ) ) > 1 ) { if ( ! empty ( $ permission ) ) { return AccessResult :: allowedIfHasPermission ( $ account , $ permission ) ; } else { return AccessResult :: allowed ( ) ; } } return AccessResult :: forbidden ( ) ; }
Checks access to the overview based on permissions and translatability.

@param \Drupal\Core\Routing\RouteMatchInterface $route_match
The route_match to check against.
@param \Drupal\Core\Session\AccountInterface $account
The account to check access for.
@param string $permission
(optional) The permission.

@codingStandardsIgnoreStart until https://www.drupal.org/project/coder/issues/3013953 is fixed
@return \Drupal\Core\Access\AccessResult
Whether to grant or deny access.
@codingStandardsIgnoreEnd
Checks access to the overview based on permissions and translatability .