update posts controller