fix shorturl example code (#35)

master
Leonard Wang 4 years ago committed by GitHub
parent 33eb2936e8
commit 1e85f74fd8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -10,12 +10,14 @@ import (
)
type ExpandLogic struct {
svcCtx *svc.ServiceContext
ctx context.Context
logx.Logger
}
func NewExpandLogic(ctx context.Context, svcCtx *svc.ServiceContext) ExpandLogic {
return ExpandLogic{
svcCtx: svcCtx,
ctx: ctx,
Logger: logx.WithContext(ctx),
}

@ -10,12 +10,14 @@ import (
)
type ShortenLogic struct {
svcCtx *svc.ServiceContext
ctx context.Context
logx.Logger
}
func NewShortenLogic(ctx context.Context, svcCtx *svc.ServiceContext) ShortenLogic {
return ShortenLogic{
svcCtx: svcCtx,
ctx: ctx,
Logger: logx.WithContext(ctx),
}

Loading…
Cancel
Save