UnifiedFileDeleted not triggered when block with page files is deleted


Well, the title says it all. I added UnififedFileDeleted event handler which gets called nicely when I delete files in file explorer. But when I create a block, page file folder for it, put some files into it and go and delete the block. Event isn't triggered even when I empty the trash. Is this a bug or do i handle it differently?

Just thought to try regular pages. Results are the same. Deleting the pages, with files in page file folder, doesn't trigger deleted event.

#66260 Feb 26, 2013 6:57
  • Johan Petersson
    Member since: 2007


    Pagefiles are not deleted when their corresponding pages are. The files could be inserted on other pages if the editor has copied the url, that's probably why.

    In admin there is scheduled job that removes unused pagefiles.

    #66265 Edited, Feb 26, 2013 9:43

    Errr... Okay. I've never heard such a behavior where you delete container but not the contents. Scheduled job wont do in my case. I have rethink this from the scratch.

    Thanks anyway.

    #66272 Feb 26, 2013 10:48
  • Johan Petersson
    Member since: 2007

    You can delete the pagefiles folder when a block and/or page is deleted by listening to events in ContentRepository.

    #66273 Feb 26, 2013 10:54