Skip to content

Commit ed85dd3

Browse files
committed
Add some logging.
1 parent c5a3736 commit ed85dd3

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

browser-extension/src/lib/enhancers/github.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import hljs from 'highlight.js'
22
import OverType, { type OverTypeInstance } from '../../overtype/overtype'
33
import type { CommentEnhancer, CommentSpot } from '../enhancer'
4+
import { logger } from '../../lib/logger'
45

56
const GITHUB_SPOT_TYPES = [
67
'GH_PR_ADD_COMMENT',
@@ -35,7 +36,10 @@ export class GitHubAddCommentEnhancer implements CommentEnhancer<GitHubAddCommen
3536
}
3637

3738
// Parse GitHub URL structure: /owner/repo/issues/123 or /owner/repo/pull/456
39+
logger.debug(`${this.constructor.name} examing url`, window.location.pathname)
40+
3841
const match = window.location.pathname.match(/^\/([^/]+)\/([^/]+)(?:\/pull\/(\d+))/)
42+
logger.debug(`${this.constructor.name} found match`, window.location.pathname)
3943
if (!match) return null
4044
const [, owner, repo, numberStr] = match
4145
const slug = `${owner}/${repo}`

0 commit comments

Comments
 (0)