Added missing if(debug) for trade log abort.