We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 16551 ☆ A M B ☆
    • 54 Posts
    Hi there.
    Is it possible, that there is an error in the file "manager > processors > unpublish_content.processor.php"?
    I think, that the invokeEvent is written wrong.

    Instead of
    $modx->invokeEvent("OnDocUnpublished",array("docid"=>$id));

    it should be
    $modx->invokeEvent("OnDocUnPublished",array("docid"=>$id));

    with a capitelized "P".

    At least that’s how it is written in the database "sytem_eventnames" and I can’t call any function in a plugin when using
    case 'OnDocUnpublished':

    or
    case 'OnDocUnPublished':


    Sorry for my bad English. I hope you get what I’m up to...
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      It definitely has to be one or the other, so either the database is wrong or the event name in the processor file is.
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 16551 ☆ A M B ☆
        • 54 Posts
        Thank you.
        So can I fix that in the processor file without running into any trouble? Is there any other known plugin using this event or even modX by itself?
        Best regards
        Lars
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          Any plugins would have run into your same problem, so I doubt if you’ll break anything.
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org