edited controller newPost.java