[Directory]: many bug fixes