moved rmdir to setTimeout()