code: func CursorToOffset(cursor ConnectionCursor) (int, error) {
  	str := ""
  	b, err := base64.StdEncoding.DecodeString(string(cursor))
  	if err == nil {
  		str = string(b)
  	}
  	str = strings.Replace(str, PREFIX, "", -1)
  	offset, err := strconv.Atoi(str)
  	if err != nil {
  		return 0, errors.New("Invalid cursor")
  	}
  	return offset, nil
  }
docs: // Re-derives the offset from the cursor string.