Fixed bug with orientation.