Fixed some few minor bugs.