fixup! Fix directory content counting before file operation.