Fixed removeDir call scope and mkDir mode.