cleaned up traces, unused vars