remove duplicate field ‘dir’