fix silly bug, check for detail[5] not detail