File tree Expand file tree Collapse file tree 1 file changed +14
-15
lines changed Expand file tree Collapse file tree 1 file changed +14
-15
lines changed Original file line number Diff line number Diff line change @@ -15,19 +15,18 @@ module.exports = async (context: SolidarityRunContext): Promise<void> => {
1515 )
1616
1717 // run the array of promises you just created
18- await Promise . all ( checks )
19- . then ( results => {
20- const updates = flatten ( results )
21- if ( isEmpty ( updates ) ) {
22- print . success ( '\n No Changes' )
23- } else {
24- setSolidaritySettings ( solidaritySettings , context )
25- const ruleMessage = pluralize ( 'Rule' , updates . length , true )
26- print . success ( `\n ${ ruleMessage } updated` )
27- }
28- } )
29- . catch ( err => {
30- print . error ( err )
31- process . exit ( 2 )
32- } )
18+ try {
19+ const results = await Promise . all ( checks )
20+ const updates = flatten ( results )
21+ if ( isEmpty ( updates ) ) {
22+ print . success ( '\n No Changes' )
23+ } else {
24+ setSolidaritySettings ( solidaritySettings , context )
25+ const ruleMessage = pluralize ( 'Rule' , updates . length , true )
26+ print . success ( `\n ${ ruleMessage } updated` )
27+ }
28+ } catch ( err ) {
29+ print . error ( err )
30+ process . exit ( 2 )
31+ }
3332}
You can’t perform that action at this time.
0 commit comments