directory check