Skip to content

Commit 32d38ce

Browse files
Update bin/cmd.js
Co-authored-by: Jacob Smith <3012099+JakobJingleheimer@users.noreply.github.com>
1 parent 75ac031 commit 32d38ce

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

bin/cmd.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,12 +141,12 @@ if (args.length === 1 && args[0] === '-') {
141141
}
142142

143143
// Replace args with the commit data directly
144-
args.splice(0, 1, ...commits.map(commit => {
144+
for (let i = 0; i < commits.length; i++) {
145145
if (!commit.id || !commit.message) {
146146
throw new Error('Each commit must have "id" and "message" properties')
147147
}
148-
return { sha: commit.id, ...commit }
149-
}))
148+
args[i] = { sha: commit.id, ...commit }
149+
}
150150
run()
151151
} catch (err) {
152152
console.error('Error parsing JSON input:', err.message)

0 commit comments

Comments
 (0)