Finished fix bugs