code: func (c idExporter) findIDs() ([]id, error) {
  	var idsList []id
  	_, err := c.dbMap.Select(
  		&idsList,
  		`SELECT id
  		FROM registrations
  		WHERE contact != 'null' AND
  			id IN (
  				SELECT registrationID
  				FROM certificates
  				WHERE expires >= :expireCutoff
  			);`,
  		map[string]interface{}{
  			"expireCutoff": c.clk.Now().Add(-c.grace),
  		})
  	if err != nil {
  		c.log.AuditErrf("Error finding IDs: %s", err)
  		return nil, err
  	}
  
  	return idsList, nil
  }
docs: // Find all registration IDs with unexpired certificates.