Fix bug in placing order