- getStatusLogic 类型断言修复(*user.User) - restoreLogic 事务拆分为单条处理 + appAccountToken 解析 - attachTransactionLogic 提取 ParseProductIdDuration 共享函数 - 新增 config_helper.go 统一 Apple API 配置加载 - reconcileLogic 补充 BundleID 配置读取 - activateOrderLogic 邀请赠送天数逻辑完善 Co-Authored-By: claude-flow <ruv@ruv.net>
This commit is contained in:
@@ -5,6 +5,7 @@ import (
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/perfect-panel/server/internal/model/user"
|
||||
"github.com/perfect-panel/server/internal/svc"
|
||||
"github.com/perfect-panel/server/internal/types"
|
||||
"github.com/perfect-panel/server/pkg/constant"
|
||||
@@ -28,7 +29,7 @@ func NewGetStatusLogic(ctx context.Context, svcCtx *svc.ServiceContext) *GetStat
|
||||
}
|
||||
|
||||
func (l *GetStatusLogic) GetStatus() (*types.GetAppleStatusResponse, error) {
|
||||
u, ok := l.ctx.Value(constant.CtxKeyUser).(*struct{ Id int64 })
|
||||
u, ok := l.ctx.Value(constant.CtxKeyUser).(*user.User)
|
||||
if !ok || u == nil {
|
||||
return nil, errors.Wrapf(xerr.NewErrCode(xerr.InvalidAccess), "invalid access")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user