refactor: save dates as unix timestamps in database

This commit is contained in:
Elias Schneider
2024-10-23 10:02:11 +02:00
parent 0a07344139
commit b39bc4f79a
12 changed files with 135 additions and 24 deletions

View File

@@ -3,7 +3,7 @@ package model
import (
"github.com/go-webauthn/webauthn/protocol"
"github.com/go-webauthn/webauthn/webauthn"
"time"
"github.com/stonith404/pocket-id/backend/internal/model/types"
)
type User struct {
@@ -61,7 +61,7 @@ func (u User) WebAuthnCredentialDescriptors() (descriptors []protocol.Credential
type OneTimeAccessToken struct {
Base
Token string
ExpiresAt time.Time
ExpiresAt datatype.DateTime
UserID string
User User