Made changes to post controller