referral

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AlreadyReferred      string = "User already referred"
	ReferrerDoesNotExist string = "Referrer does not exist"
	SelfReferralError    string = "A user cannot refer themselves"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct {
	pb.UnimplementedReferralsServer
	// contains filtered or unexported fields
}

func NewHandler

func NewHandler(config util.Config, store db.Store) Handler

func (*Handler) GetReferrer

func (h *Handler) GetReferrer(ctx context.Context, req *pb.GetReferrerRequest) (*pb.GetReferrerResponse, error)

func (*Handler) ListReferrals

func (h *Handler) ListReferrals(ctx context.Context, req *pb.ListReferralsRequest) (*pb.ListReferralsResponse, error)

Jump to

Keyboard shortcuts

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