code: func (a *ACLs) IsAllowed(c context.Context, host, project string) (bool, error) {
  	// Convert Gerrit to Git hosts.
  	if strings.HasSuffix(host, "-review.googlesource.com") {
  		host = strings.TrimSuffix(host, "-review.googlesource.com") + ".googlesource.com"
  	}
  	hacls, configured := a.hosts[host]
  	if !configured {
  		return false, nil
  	}
  	if pacls, projKnown := hacls.projects[project]; projKnown {
  		return a.belongsTo(c, hacls.readers, pacls.readers)
  	}
  	return a.belongsTo(c, hacls.readers)
  }
docs: // IsAllowed returns whether current identity has been granted read access to
  // given Git/Gerrit project.