File tree 1 file changed +3
-2
lines changed
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -60,15 +60,16 @@ export async function prepareGitlabNotificationData(events: GitlabEventWithRepoD
60
60
const firstEvent = item . events [ 0 ] ;
61
61
const { target_type } = firstEvent ;
62
62
if ( target_type === 'Milestone' ) return item ;
63
- const isNote =
64
- target_type === 'Note' || target_type === 'DiffNote' || target_type === 'DiscussionNote' ;
63
+ const isNote = target_type ?. includes ( 'Note' ) ;
65
64
let type : 'Issue' | 'MergeRequest' = 'MergeRequest' ;
66
65
if (
67
66
( isNote && firstEvent . note . noteable_type === 'Issue' ) ||
68
67
( 'target_type' in firstEvent && target_type === 'Issue' )
69
68
) {
70
69
type = 'Issue' ;
71
70
}
71
+ console . log ( 'event' , firstEvent ) ;
72
+
72
73
const data = await fetchGitlab < GitlabMergeRequest | GitlabIssue > (
73
74
`projects/${ firstEvent . repository . encoded } /${
74
75
type === 'Issue' ? 'issues' : 'merge_requests'
You can’t perform that action at this time.
0 commit comments