mirror of
https://github.com/pocket-id/pocket-id.git
synced 2026-10-03 08:19:04 +02:00
feat: include passkey icons based on AAGUID (#1756)
This commit is contained in:
@@ -20,9 +20,17 @@ type WebauthnCredential struct {
|
||||
BackupEligible bool `json:"backupEligible"`
|
||||
BackupState bool `json:"backupState"`
|
||||
|
||||
AAGUID string `gorm:"column:aaguid;default:00000000-0000-0000-0000-000000000000"`
|
||||
|
||||
UserID string
|
||||
}
|
||||
|
||||
// HasIcon reports whether an icon is embedded for this credential's authenticator
|
||||
// It is mapped onto the DTO so the frontend knows upfront whether an icon is worth requesting
|
||||
func (c WebauthnCredential) HasIcon() bool {
|
||||
return utils.HasAuthenticatorIcon(c.AAGUID)
|
||||
}
|
||||
|
||||
type AuthenticatorTransportList []protocol.AuthenticatorTransport //nolint:recvcheck
|
||||
|
||||
// Scan and Value methods for GORM to handle the custom type
|
||||
|
||||
Reference in New Issue
Block a user