userutil

package
v0.13.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 12, 2023 License: Apache-2.0 Imports: 6 Imported by: 12

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MakeUserID

func MakeUserID(localpart string, server spec.ServerName) string

MakeUserID generates user ID from localpart & server name

func ParseUsernameParam

func ParseUsernameParam(usernameParam string, cfg *config.Global) (string, spec.ServerName, error)

ParseUsernameParam extracts localpart from usernameParam. usernameParam can either be a user ID or just the localpart/username. If serverName is passed, it is verified against the domain obtained from usernameParam (if present) Returns error in case of invalid usernameParam.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL