Refactoring calling pre-, post-processor functions