Skip to content

Commit

Permalink
fix(api): delete by regexp
Browse files Browse the repository at this point in the history
  • Loading branch information
darkweak committed Oct 25, 2024
1 parent b179236 commit 07d53bf
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/api/souin.go
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,9 @@ func (s *SouinAPI) HandleRequest(w http.ResponseWriter, r *http.Request) {
s.purgeMapping()
} else {
submatch := keysRg.FindAllStringSubmatch(r.RequestURI, -1)[0][1]
s.BulkDelete(submatch, true)
for _, current := range s.storers {
current.DeleteMany(submatch)
}
}
} else {
ck, _ := s.surrogateStorage.Purge(r.Header)
Expand Down

0 comments on commit 07d53bf

Please sign in to comment.