25 lines
367 B
Go
25 lines
367 B
Go
package interfaces
|
|
|
|
import (
|
|
"context"
|
|
|
|
"gitea.konchin.com/go2025/backend/models"
|
|
)
|
|
|
|
type Database interface {
|
|
GetSession(
|
|
ctx context.Context,
|
|
loginToken string,
|
|
) (models.Session, error)
|
|
|
|
UpdateRefreshToken(
|
|
ctx context.Context,
|
|
userId string,
|
|
) (models.Session, error)
|
|
|
|
UpdateLoginToken(
|
|
ctx context.Context,
|
|
userId string,
|
|
) (string, error)
|
|
}
|