Fixed small bug when setting path