Faulty snippet detection on GitHub issues
Created by: chrismwendt
- Visit https://github.com/gorilla/mux/issues/381
- Notice hovers don't work on the first snippet
It looks like this code assumes that the first <a>
tag within a comment that links to a URL that can be parsed by getGitHubState(anchor.href)
is a snippet, but in that issue it's actually a link to a commit.
One solution is to not stop after the first is found, and to tighten the URL regex.