INNER CODE UNIT · Go

Exists

GGP1/kure · commands/util.go:203

func Exists(db *bolt.DB, name string, obj object) error {
	records, objType, err := listNames(db, obj)
	if err != nil {
		return err
	}

	return exists(records, name, objType)
}

// FmtExpires returns expires formatted.
func FmtExpires(expires string) (string, error) {
	switch strings.ToLower(expires) {
	case "never", "", " ", "0", "0s":
		return "Never", nil

	default:
		expires = strings.ReplaceAll(expires, "-", "/")

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…