fix(files): isSharing always return true

This commit is contained in:
hexxa 2021-09-12 17:05:28 +08:00 committed by Hexxa
parent f91723eab7
commit e462c349a5
4 changed files with 22 additions and 17 deletions

View file

@ -839,8 +839,8 @@ func (h *FileHandlers) IsSharing(c *gin.Context) {
return
}
_, ok := h.deps.FileInfos().GetSharing(dirPath)
if ok {
exist, ok := h.deps.FileInfos().GetSharing(dirPath)
if exist && ok {
c.JSON(q.Resp(200))
} else {
c.JSON(q.Resp(404))