Skip to content
This repository has been archived by the owner on Jan 31, 2024. It is now read-only.

Commit

Permalink
search: log pattern on REPORT
Browse files Browse the repository at this point in the history
  • Loading branch information
SamuAlfageme committed Nov 16, 2022
1 parent 4546c7f commit 16d7c15
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion internal/http/services/owncloud/ocdav/report.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,16 @@ const (
func (s *svc) handleReport(w http.ResponseWriter, r *http.Request, ns string) {
ctx := r.Context()
log := appctx.GetLogger(ctx)
log.Info().Msgf("hugo: searching in path: %s", r.URL.Path)

rep, status, err := readReport(r.Body)
if err != nil {
log.Error().Err(err).Msg("error reading report")
w.WriteHeader(status)
return
}

log.Info().Msgf("hugo: searching in path: %s with pattern: %s", r.URL.Path, rep.SearchFiles.Search.Pattern)

if rep.SearchFiles != nil {
s.doSearchFiles(w, r, rep.SearchFiles)
return
Expand Down

0 comments on commit 16d7c15

Please sign in to comment.