Alter onBeforeWrite behaviour (works with LinkedFolderDecorator)