Merge pull request #575 from rocboss/dev

fixed nil user err in tweet detail logic
pull/581/head
北野 - Michael 2 months ago committed by GitHub
commit b28940b744
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -532,7 +532,7 @@ func (s *looseSrv) TweetDetail(req *web.TweetDetailReq) (*web.TweetDetailResp, m
// 检测访问权限
// TODO: 提到最前面去检测
switch {
case req.User.IsAdmin:
case req.User != nil && req.User.IsAdmin:
break
case post.Visibility == core.PostVisitPublic:
break

Loading…
Cancel
Save