go.charczuk.com@v0.0.0-20240327042549-bc490516bd1a/projects/chirp/pkg/model/user_info.go (about)

     1  /*
     2  
     3  Copyright (c) 2023 - Present. Will Charczuk. All rights reserved.
     4  Use of this source code is governed by a MIT license that can be found in the LICENSE file at the root of the repository.
     5  
     6  */
     7  
     8  package model
     9  
    10  import "go.charczuk.com/sdk/uuid"
    11  
    12  // UserInfo contains additional user data
    13  // outside what we get from apputil.User.
    14  type UserInfo struct {
    15  	UserID      uuid.UUID `db:"user_id,pk"`
    16  	IsPrivate   bool      `db:"is_private"`
    17  	IsAdmin     bool      `db:"is_admin"`
    18  	Description string    `db:"description"`
    19  	HeroURL     string    `db:"hero_url"`
    20  }
    21  
    22  // TableName returns the mapped table name.
    23  func (ui UserInfo) TableName() string { return "user_info" }