mirror of
https://github.com/twofas/2fas-server.git
synced 2024-12-12 12:09:56 +01:00
20 lines
246 B
Go
20 lines
246 B
Go
|
package pairing
|
||
|
|
||
|
import (
|
||
|
"time"
|
||
|
)
|
||
|
|
||
|
type MobileDevice struct {
|
||
|
DeviceID string
|
||
|
FCMToken string
|
||
|
}
|
||
|
|
||
|
type PairingInfo struct {
|
||
|
Device MobileDevice
|
||
|
PairedAt time.Time
|
||
|
}
|
||
|
|
||
|
func (pi *PairingInfo) IsPaired() bool {
|
||
|
return !pi.PairedAt.IsZero()
|
||
|
}
|