Skip to content

Commit c63dca3

Browse files
simplify construction of approvableCancelledJobSpecs
Co-authored-by: Copilot <[email protected]>
1 parent 6d9785c commit c63dca3

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/screens/JobProposal/SpecsView.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -144,10 +144,9 @@ export const SpecsView = withStyles(styles)(
144144
}, [specs])
145145

146146
const approvableCancelledJobSpecs = sortedSpecs
147-
.map((spec, idx) => ({ spec, idx }))
148-
.filter((el) => el.spec.status === 'CANCELLED')
147+
.filter((spec) => spec.status === 'CANCELLED')
149148
.slice(0, 2)
150-
.map((el) => el.spec.id)
149+
.map((spec) => spec.id)
151150

152151
const renderActions = (
153152
status: SpecStatus,

0 commit comments

Comments
 (0)