Fixed a few bugs in post.js.