Files
medusa-store/packages/medusa-plugin-sendgrid/src/subscribers/user.js
Kasper Fabricius Kristensen 90121dd19d fix: reset user password subscription in sendgrid plugin (#1072)
* fixed reset password subscription

* cleanup
2022-02-21 19:52:03 +01:00

18 lines
392 B
JavaScript

class UserSubscriber {
constructor({ sendgridService, eventBusService }) {
this.sendgridService_ = sendgridService
this.eventBus_ = eventBusService
this.eventBus_.subscribe("user.password_reset", async (data) => {
await this.sendgridService_.sendNotification(
"user.password_reset",
data,
null
)
})
}
}
export default UserSubscriber