Globally renamed property RedirectUrl to LongUrl

This commit is contained in:
2022-08-27 14:16:23 +02:00
parent 590906d555
commit 092cbcfdd1
7 changed files with 14 additions and 14 deletions

View File

@ -39,7 +39,7 @@ func (l *ExpandUrlLogic) ExpandUrl(req *types.ExpandReq) (resp *types.ExpandResp
}
resp = &types.ExpandResp{
RedirectUrl: urls[0].RedirectUrl,
LongUrl: urls[0].LongUrl,
}
return resp, err

View File

@ -30,8 +30,8 @@ func (l *ShortenUrlLogic) ShortenUrl(req *types.ShortenReq) (resp *types.Shorten
insertUrl := db.UrlTable.InsertBuilder().TTL(30 * time.Second).Query(l.svcCtx.DB)
insertUrl.BindStruct(db.UrlModel{
ID: id,
RedirectUrl: req.RedirectUrl,
ID: id,
LongUrl: req.LongUrl,
})
if err := insertUrl.ExecRelease(); err != nil {