Before pull
Fixed lots of bugs