Bug fixing in remove file cmdlet.