Skip to content

Commit 3e7eaa4

Browse files
committed
maybe?
1 parent 6861f77 commit 3e7eaa4

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

packages/plexus-core/src/action.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,11 +169,10 @@ export function _action<Returns, Fn extends ActionFunction>(
169169
'An error occurred during the execution of an action',
170170
{ origin: 'action' }
171171
)
172-
return
173172
}
174173
}
175174
// return the proxy function
176-
return newAction as InnerFunction<typeof fn>
175+
return newAction as InnerFunction<Fn>
177176

178177
// const newAction = async (...args) => {
179178
// try {

tests/action.test.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ describe('Testing Action Function', () => {
6969
)
7070
})
7171
const data = await myAction()
72+
console.log(data)
7273
expect(data).toBe(successMsg)
7374
})
7475

@@ -80,7 +81,7 @@ describe('Testing Action Function', () => {
8081
if (counter === 2) throw new Error('test error')
8182
})
8283

83-
await myAction()
84+
myAction()
8485
const data = await myAction()
8586
expect(data).toBeDefined()
8687
})

0 commit comments

Comments
 (0)