mirror of
https://github.com/nkanaev/yarr.git
synced 2025-05-24 00:33:14 +00:00
fix
This commit is contained in:
parent
1f02bde5e1
commit
0ea313d945
@ -242,8 +242,8 @@ func (s *Server) handleItem(c *router.Context) {
|
||||
c.Out.WriteHeader(http.StatusBadRequest)
|
||||
return
|
||||
}
|
||||
item.Content = scraper.Sanitize(item.Link, item.Content)
|
||||
item.Description = scraper.Sanitize(item.Link, item.Description)
|
||||
item.Content = sanitizer.Sanitize(item.Link, item.Content)
|
||||
item.Description = sanitizer.Sanitize(item.Link, item.Description)
|
||||
|
||||
c.JSON(http.StatusOK, item)
|
||||
} else if c.Req.Method == "PUT" {
|
||||
@ -425,7 +425,7 @@ func (s *Server) handlePageCrawl(c *router.Context) {
|
||||
c.Out.WriteHeader(http.StatusNoContent)
|
||||
return
|
||||
}
|
||||
content = scraper.Sanitize(url, content)
|
||||
content = sanitizer.Sanitize(url, content)
|
||||
c.JSON(http.StatusOK, map[string]string{
|
||||
"content": content,
|
||||
})
|
||||
|
Loading…
x
Reference in New Issue
Block a user