package database

import (
	"strings"

	"github.com/google/uuid"
)

func generateUUID() uuid.UUID {
	return uuid.New()
}

// detectIPVersion determines if a prefix is IPv4 (returns 4) or IPv6 (returns 6)
func detectIPVersion(prefix string) int {
	if strings.Contains(prefix, ":") {
		return ipVersionV6
	}

	return ipVersionV4
}
