remove default values

This commit is contained in:
İsmail
2024-11-07 16:14:34 +03:00
parent daab053b6a
commit 90910a958b
5 changed files with 6 additions and 6 deletions

View File

@@ -308,7 +308,7 @@ type UserInfo struct {
IsServiceUser bool `json:"is_service_user"`
IsBlocked bool `json:"is_blocked"`
NonDeletable bool `json:"non_deletable"`
LastLogin time.Time `json:"last_login" gorm:"default:null"`
LastLogin time.Time `json:"last_login"`
Issued string `json:"issued"`
IntegrationReference integration_reference.IntegrationReference `json:"-"`
Permissions UserPermissions `json:"permissions"`

View File

@@ -40,7 +40,7 @@ type Peer struct {
InactivityExpirationEnabled bool
// LastLogin the time when peer performed last login operation
LastLogin time.Time `gorm:"default:null"`
LastLogin time.Time
// CreatedAt records the time the peer was created
CreatedAt time.Time
// Indicate ephemeral peer attribute
@@ -51,7 +51,7 @@ type Peer struct {
type PeerStatus struct { //nolint:revive
// LastSeen is the last time peer was connected to the management service
LastSeen time.Time `gorm:"default:null"`
LastSeen time.Time
// Connected indicates whether peer is connected to the management service or not
Connected bool
// LoginExpired

View File

@@ -35,7 +35,7 @@ type PersonalAccessToken struct {
// scope could be added in future
CreatedBy string
CreatedAt time.Time
LastUsed time.Time `gorm:"default:null"`
LastUsed time.Time
}
func (t *PersonalAccessToken) Copy() *PersonalAccessToken {

View File

@@ -87,7 +87,7 @@ type SetupKey struct {
// UsedTimes indicates how many times the key was used
UsedTimes int
// LastUsed last time the key was used for peer registration
LastUsed time.Time `gorm:"default:null"`
LastUsed time.Time
// AutoGroups is a list of Group IDs that are auto assigned to a Peer when it uses this key to register
AutoGroups []string `gorm:"serializer:json"`
// UsageLimit indicates the number of times this key can be used to enroll a machine.

View File

@@ -74,7 +74,7 @@ type User struct {
// Blocked indicates whether the user is blocked. Blocked users can't use the system.
Blocked bool
// LastLogin is the last time the user logged in to IdP
LastLogin time.Time `gorm:"default:null"`
LastLogin time.Time
// CreatedAt records the time the user was created
CreatedAt time.Time