justbetter / magento2-sentry

Magento 2 module to log to Sentry
MIT License
165 stars 70 forks source link

Added user context whenever possible #133

Closed indykoning closed 2 weeks ago

indykoning commented 7 months ago

Summary Currently we're only setting customer data on logs when a customer has an active session. This misses out on headless and admin errors, as well as customer data on exceptions.

Result This PR attempts to add the user type and user id with the usercontext. Then it will attempt to get user data from the admin and user session itself

indykoning commented 7 months ago

For some reason the admin gets forced to log out when the console is open in chrome This happens when interacting with the admin session in ANY way, getData, isLoggedIn, hasUser