Update and delete posts functionality