Small refactoring in view. Add post destroy API.