updated order.rb adding log function