Use a post repository to handle requests on posts

Cleaner routes
refactored cachemanager::postSaving