Fixed some little bugs