Simplify absolute dir detection