Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Jay 425 posts 652 karma points
    Jul 05, 2024 @ 09:57
    Jay
    0

    ContentPublishingNotification with CancelOperation set is still hitting into ContentPublishedNotification

    Hi All,

    I'm using Umbraco 13.3.2

    I've got a ContentPublishingNotification which checks for specific condition and if it's met will call the CancelOperation as per the example below. It's working as it shows the red panel about the error. https://docs.umbraco.com/umbraco-cms/v/13.latest-lts/reference/notifications/contentservice-notifications#usage

    But this doesn't stops the publishing as it still hits into the ContentPublishedNotification.

    So it's showing both the green panel saying content published and then the red panel error from the CancelOperation below the green panel.

    Is this a bug? Or is this how it's supposed to work?

    Is there a way to cancel publishing when I've set the CancelOperation?

    Thanks

  • Webling 4 posts 74 karma points
    Oct 21, 2024 @ 22:05
    Webling
    0

    Did you find the solution? I have the exact same issue and of course there is no help to be found in the Umbraco dev references. They'll never show a full working example, not sure why but it has always been the case.

    Sure seems to be a bug though, as the source code indicates that the edit should be cancelled.

Please Sign in or register to post replies

Write your reply to:

Draft