Some fixes to _tr