File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -6,23 +6,23 @@ async function receiveBranchUpdated(event) {
6
6
try {
7
7
const data = JSON . parse ( event . data ) ;
8
8
9
- const staleBranchAlert = document . querySelector ( '.refresh-pull-request' ) ;
9
+ const refreshPullRequest = document . querySelector ( '.refresh-pull-request' ) ;
10
10
11
- if ( ! staleBranchAlert ) {
11
+ if ( ! refreshPullRequest ) {
12
12
return ;
13
13
}
14
14
15
- const baseTarget = $ ( staleBranchAlert ) . data ( 'baseTarget' ) ;
16
- const headTarget = $ ( staleBranchAlert ) . data ( 'headTarget' ) ;
17
- const ownerName = $ ( staleBranchAlert ) . data ( 'ownerName' ) ;
18
- const repositoryName = $ ( staleBranchAlert ) . data ( 'repositoryName' ) ;
15
+ const baseTarget = $ ( refreshPullRequest ) . data ( 'baseTarget' ) ;
16
+ const headTarget = $ ( refreshPullRequest ) . data ( 'headTarget' ) ;
17
+ const ownerName = $ ( refreshPullRequest ) . data ( 'ownerName' ) ;
18
+ const repositoryName = $ ( refreshPullRequest ) . data ( 'repositoryName' ) ;
19
19
20
20
if (
21
21
[ baseTarget , headTarget ] . includes ( data . Branch ) &&
22
22
data . Owner === ownerName &&
23
23
data . Repository === repositoryName
24
24
) {
25
- staleBranchAlert . classList . add ( 'active' ) ;
25
+ refreshPullRequest . classList . add ( 'active' ) ;
26
26
}
27
27
} catch ( error ) {
28
28
console . error ( error , event ) ;
You can’t perform that action at this time.
0 commit comments