Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Previously, the application looked for favicons in `/favicon.ico`. But favicons can be anywhere on a website and the location can be defined in HTML and JSON manifests. Websites can also have multiple favicons. As a result, when a new site was added to stash-box which did not have a `/favicon.ico`, the site was created without a proper favicon. Additionally, since stash-box didn't check the filetype of the data returned by the `/favicon.ico` GET request, it stored various 404 and other redirected html pages. A non-trivial amount of logic is required to discover all favicon locations, check filetypes, and sort them. It therefore makes sense to rely on a third-party package for this job. This patch uses `go.deanishe.net/favicon`.
- Loading branch information