When workContext.CurrentUser != real current user

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
7 years ago
It's easy to reproduce the bug

Start new DEBUG session on your development computer. Plz verify that you're not logged it

Log in.

Put a product into the shopping cart, start checkout process, select a pickup point.

Go through the checkout process, on the choose payment method step try to check workContext.CurrentCustomer. There is nothing about the user you logged in - it even has no any generic attribute which shows a pickup point you selected before.

It could not be a bug. Problem that new Customer has no any generic attributes from the host Customer (logged in user). But Current customer ID != logged in Customer ID. Meanwhile on Order table I can see correct Customer ID of the logged user...
7 years ago
Note - workContext created in plugin's constructor has incorrect CurrentCustomer. When I use EngineContext.Current.Resolve<..> it returns workContext with the correct Customer in it
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.