MCPcopy Create free account
hub / github.com/auth0/auth0-cli / stringPtr

Function stringPtr

internal/cli/utils_shared.go:371–377  ·  view source on GitHub ↗

stringPtr converts a pointer of string-derived type to pointer of string. Returns nil if the input pointer is nil.

(ptr *strPtrType)

Source from the content-addressed store, hash-verified

369// stringPtr converts a pointer of string-derived type to pointer of string.
370// Returns nil if the input pointer is nil.
371func stringPtr[strPtrType ~string](ptr *strPtrType) *string {
372 if ptr == nil {
373 return nil
374 }
375 s := string(*ptr)
376 return &s
377}
378
379func parseFlexibleDate(input string) (string, error) {
380 now := time.Now().UTC()

Callers 2

TestStringPtrFunction · 0.85
updateBotDetectionCmdRunFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestStringPtrFunction · 0.68