Skip to content

Commit d2e6fd2

Browse files
Fabio PicheliFabio Picheli
authored andcommitted
fix #14: add support for enterprise github
1 parent 27188ed commit d2e6fd2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

app/background/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,8 @@ const init = (savedItems) => {
104104

105105
const start = () => setInterval(() => {
106106
if(!$('.gct-file-tree').length) {
107-
urlPullRegex = /(http|https):\/\/(www\.)?github\.com\/[-a-zA-Z0-9]*\/[-a-zA-Z0-9]*\/pull\/[0-9]*\/(files|commits)/;
108-
urlCommitRegex = /(http|https):\/\/(www\.)?github\.com\/[-a-zA-Z0-9]*\/[-a-zA-Z0-9]*\/commit/;
107+
urlPullRegex = /(http|https):\/\/(www\.)?github[\.]?[-a-zA-Z0-9]*\.com\/[-a-zA-Z0-9]*\/[-a-zA-Z0-9]*\/pull\/[0-9]*\/(files|commits)/;
108+
urlCommitRegex = /(http|https):\/\/(www\.)?github[\.]?[-a-zA-Z0-9]*\.com\/[-a-zA-Z0-9]*\/[-a-zA-Z0-9]*\/commit/;
109109

110110
isCommit = location.href.match(urlCommitRegex);
111111

0 commit comments

Comments
 (0)