Closed Omri-Levy closed 1 week ago
Latest commit: 2ebf018cf69a7c093944e77dd99b2c021132153f
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
Click here to learn what changesets are, and how to add one.
Click here if you're a maintainer who wants to add a changeset to this PR
Overall, the changes involve adding authentication checks before running customer queries in the back office application and updating a subproject commit reference in the workflows service. The useCustomerQuery
hook now checks if a user is authenticated before executing, improving security and data access control.
File Path | Summary of Changes |
---|---|
apps/.../useCustomerQuery.tsx |
Added authentication check using useIsAuthenticated hook before executing the customer query. |
services/.../data-migrations |
Updated subproject commit reference from 1b3abbfbc06f88020f1d3e19468d8960ac88ab8e to 47e614c3cfc96a9102cf49997981a1eca8260092 . |
sequenceDiagram
participant User
participant useCustomerQuery Hook
participant AuthProvider
participant CustomerService
User ->> useCustomerQuery Hook: Execute useCustomerQuery
useCustomerQuery Hook ->> AuthProvider: useIsAuthenticated()
AuthProvider -->> useCustomerQuery Hook: isAuthenticated = true/false
alt isAuthenticated == true
useCustomerQuery Hook ->> CustomerService: fetchCustomerData()
CustomerService -->> useCustomerQuery Hook: customerData
useCustomerQuery Hook -->> User: return customerData
else isAuthenticated == false
useCustomerQuery Hook -->> User: return unauthorized error
end
In the realm of code’s grand dance,
Authentication gets its chance,
Secure the data, guard the way,
Access granted, come what may.
A commit's shift, a step so spry,
On workflows wings, we soar sky-high! 🐇✨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Summary by CodeRabbit
New Features
useCustomerQuery
hook to check for user authentication status before executing the query.Internal Improvements