v6.1.6 - ApplicationEventHandler Issue with Document_AfterPublish
Hello,
I have registered a new event on Application Started which looks like:
Document.AfterPublish += Document_AfterPublish; private void Document_AfterPublish(Document sender, PublishEventArgs e) { //push some stuff to an api }
Now this all seems to work fine - it does everything I want it to - but it is also doing it if the publish in Umbraco fails on validation. So for example:
a mandatory field has not been filled in
Press save and publish
stuff sent to api (technical term!)
error messages regarding validation - node is not published
So the Document.AfterPublish event seems to be firing whether the node has been published or not. Has anyone else had this issue? Maybe i'm missing something?
v6.1.6 - ApplicationEventHandler Issue with Document_AfterPublish
Hello,
I have registered a new event on Application Started which looks like:
Now this all seems to work fine - it does everything I want it to - but it is also doing it if the publish in Umbraco fails on validation. So for example:
Thanks in advance,
Kenny
You should use the new events:
Smashing!! :)
That works a treat - thanks a lot Kipusoep! :)
is working on a reply...