Skip to content

Commit

Permalink
Merge pull request #964 from application-research/pythonicode/dev
Browse files Browse the repository at this point in the history
Pythonicode/dev
  • Loading branch information
alvin-reyes authored Mar 30, 2023
2 parents 852d7ec + 0273255 commit 9de9a65
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion collections/collections.go
Original file line number Diff line number Diff line change
Expand Up @@ -155,12 +155,13 @@ func GetDirectoryContents(refs []util.ContentWithPath, queryDir, coluuid string)

if directoryContent != nil { // if there was content
if directoryContent.Type == CidTypeDir { // if the content was a directory
subDir := directoryContent.Dir
subDir := filepath.Join(directoryContent.Dir, directoryContent.Name)
if dirs[subDir] { // if the directory had already been added to response, continue
continue
}
dirs[subDir] = true
}

result = append(result, directoryContent)
}
}
Expand Down
2 changes: 1 addition & 1 deletion util/misc.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ func NewBinder(log *zap.SugaredLogger) binder {
func (b binder) Bind(i interface{}, c echo.Context) error {
defer func() {
if err := c.Request().Body.Close(); err != nil {
b.log.Warnf("failed to close request body: %s", err)
log.Warnf("failed to close request body: %s", err)
}
}()

Expand Down

0 comments on commit 9de9a65

Please sign in to comment.