fixed deletion of history dir