Initial open source release
This commit is contained in:
commit
74992e893f
377 changed files with 118084 additions and 0 deletions
15
internal/store/updatestate.go
Normal file
15
internal/store/updatestate.go
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
package store
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"telesrv/internal/domain"
|
||||
)
|
||||
|
||||
// UpdateStateStore 持久化 auth_key + user 维度的 pts/qts/seq 状态,避免同一设备换号串状态。
|
||||
type UpdateStateStore interface {
|
||||
Get(ctx context.Context, authKeyID [8]byte, userID int64) (domain.UpdateState, bool, error)
|
||||
Save(ctx context.Context, authKeyID [8]byte, userID int64, state domain.UpdateState) error
|
||||
Delete(ctx context.Context, authKeyID [8]byte, userID int64) error
|
||||
DeleteAuthKey(ctx context.Context, authKeyID [8]byte) error
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue