Fixed bug with building