File tree Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -291,7 +291,7 @@ const stateSelector = [
291
291
'[class^="StateLabel"]' ,
292
292
] . join ( ',' ) ;
293
293
294
- export const isDraftPR = ( ) : boolean => isPR ( ) && $ ( stateSelector ) ! . textContent ! . trim ( ) === 'Draft' ;
294
+ export const isDraftPR = ( ) : boolean => $ ( stateSelector ) ? .textContent ! . trim ( ) === 'Draft' ;
295
295
export const isOpenPR = ( ) : boolean => {
296
296
if ( ! isPR ( ) ) {
297
297
return false ;
@@ -302,11 +302,7 @@ export const isOpenPR = (): boolean => {
302
302
} ;
303
303
304
304
export const isMergedPR = ( ) : boolean => {
305
- if ( ! isPR ( ) ) {
306
- return false ;
307
- }
308
-
309
- const status = $ ( stateSelector ) ! . textContent ! . trim ( ) ;
305
+ const status = $ ( stateSelector ) ?. textContent ! . trim ( ) ;
310
306
return status === 'Merged' ;
311
307
} ;
312
308
You can’t perform that action at this time.
0 commit comments