update post management function