handle directory traversing