Skip to content

Commit

Permalink
fix: Add konnector slug in fake trigger passed to onLoginSuccess
Browse files Browse the repository at this point in the history
This information is needed by a b2c app
  • Loading branch information
doubleface authored and doubleface committed Dec 1, 2022
1 parent f40a3c7 commit 205af03
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion packages/cozy-harvest-lib/src/components/FlowProvider.jsx
Expand Up @@ -141,7 +141,8 @@ export class FlowProvider extends Component {
// created, this is why a trigger like object is created here
const triggerLike = {
message: {
account: flow?.account?._id
account: flow?.account?._id,
konnector: flow?.konnector?.slug
},
...flow.trigger
}
Expand Down
Expand Up @@ -127,7 +127,8 @@ describe('FlowProvider', () => {
expect(onLoginSuccess).toHaveBeenCalledWith(
expect.objectContaining({
message: {
account: 'account-id'
account: 'account-id',
konnector: 'konnectorslug'
}
})
)
Expand Down

0 comments on commit 205af03

Please sign in to comment.