Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I have some code within the MemberService_Saving event which creates some content nodes and media nodes based on the member that is created. The issue I am having is that the event is being fired multiple times, so as well as the SavedEntity being the Member that has been created with the Member name, the event is also being fired a few times with SavedEntity node name being the username of the member that I created!!
Does anyone know why this might be happening or has anyone come across this issue before and found a resolution??
If you're calling .Save in your code the code might run again. If you don't want the events to be fired you can do this: .Save(raiseEvents: false)
The issue I am having is that it is the standard save event when creating a member via the admin members section that is making the event fire multiple times. None of my code touches or tries to resave the member and instead it is only content and media nodes that are created so shouldn't have an effect on any member events.
Maybe you're using a package that tries to save it multiple times?
I do have the MemberListView for Umbraco 7package installed, but regardless of wether I use that package to create the member or use the bog standard member creation functionality I still get the same result :/
This issue appears to be related to this:
It feels like some refactoring is going on in the Membership area of Umbraco that is causing these things as I'm finding that saves when not changing a "fixed" member property result in the IMember in the event not having those properties at all. Looking at this multiple save I've dumped out the stack trace in the log file and I can see two separate paths through the code resulting the MemberService.Saving getting fired. I'll attach the stack traces to the issue above.
Serious necro-posting: but HOW can this still be a problem in 8.10???
I have the same issue in 8.11.1
fires three times
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted