Improvements to the WordPress migrator

Here are some improvements to the WordPress migrator I collected while importing my own blog archives into hexo. Reasoning are described in each commit message, feel free to leave comment if you have further question to clarify.