diff --git a/internal/database/sessions/models.go b/internal/database/sessions/models.go index f92e1a629..4eeb7e235 100644 --- a/internal/database/sessions/models.go +++ b/internal/database/sessions/models.go @@ -16,27 +16,12 @@ var ( ErrUserNotFound = echo.NewHTTPError(http.StatusNotFound, "User not found") ) -// Define the credential structure matching our frontend data -type Credential struct { - ID string `json:"id"` - RawID string `json:"rawId"` - Type string `json:"type"` - AuthenticatorAttachment string `json:"authenticatorAttachment"` - Transports []string `json:"transports"` - ClientExtensionResults map[string]interface{} `json:"clientExtensionResults"` - Response struct { - AttestationObject string `json:"attestationObject"` - ClientDataJSON string `json:"clientDataJSON"` - } `json:"response"` -} - type User struct { gorm.Model - Address string `json:"address"` - Handle string `json:"handle"` - Name string `json:"name"` - CID string `json:"cid"` - Credentials []*Credential `json:"credentials"` + Address string `json:"address"` + Handle string `json:"handle"` + Name string `json:"name"` + CID string `json:"cid"` } type Session struct { diff --git a/internal/database/sessions/sqlite.go b/internal/database/sessions/sqlite.go index 3a54def51..8bb73d528 100644 --- a/internal/database/sessions/sqlite.go +++ b/internal/database/sessions/sqlite.go @@ -20,7 +20,6 @@ func NewGormDB(env config.Env) (*gorm.DB, error) { // Migrate the schema db.AutoMigrate(&Session{}) db.AutoMigrate(&User{}) - return db, nil } diff --git a/internal/gateway/handlers/index/views.templ b/internal/gateway/handlers/index/views.templ index 633808858..3f9fde21b 100644 --- a/internal/gateway/handlers/index/views.templ +++ b/internal/gateway/handlers/index/views.templ @@ -10,21 +10,21 @@ templ InitialView() { @layout.Container() { @text.Header("Sonr.ID", "The decentralized identity layer for the web.")