File tree Expand file tree Collapse file tree 1 file changed +28
-17
lines changed Expand file tree Collapse file tree 1 file changed +28
-17
lines changed Original file line number Diff line number Diff line change @@ -42,23 +42,34 @@ Release.define({
42
42
return Release . abort ( "Error getting issues." , error ) ;
43
43
}
44
44
45
- var changelog = issues . map ( function ( issue ) {
46
- var component = "(none)" ;
47
-
48
- issue . labels . forEach ( function ( label ) {
49
- if ( / ^ c o m p o n e n t : / i. test ( label . name ) ) {
50
- component = label . name . substring ( 11 ) ;
51
- }
52
- } ) ;
53
-
54
- return [
55
- "#" + issue . number ,
56
- component ,
57
- issue . title
58
- ] . sort ( function ( a , b ) {
59
- return a . component > b . component ? 1 : - 1 ;
60
- } ) . join ( "\t" ) ;
61
- } ) . join ( "\n" ) + "\n" ;
45
+ var changelog = issues
46
+
47
+ // Remove pull requests from results
48
+ . filter ( function ( issue ) {
49
+ return ! issue . pull_request ;
50
+ } )
51
+
52
+ // Convert each issue to text
53
+ . map ( function ( issue ) {
54
+ var component = "(none)" ;
55
+
56
+ issue . labels . forEach ( function ( label ) {
57
+ if ( / ^ c o m p o n e n t : / i. test ( label . name ) ) {
58
+ component = label . name . substring ( 11 ) ;
59
+ }
60
+ } ) ;
61
+
62
+ return [
63
+ "#" + issue . number ,
64
+ component ,
65
+ issue . title
66
+ ] . sort ( function ( a , b ) {
67
+ return a . component > b . component ? 1 : - 1 ;
68
+ } ) . join ( "\t" ) ;
69
+ } )
70
+
71
+ // Concatenate the issues into a string
72
+ . join ( "\n" ) + "\n" ;
62
73
63
74
callback ( changelog ) ;
64
75
} ) ;
You can’t perform that action at this time.
0 commit comments