Small error correction on line 56 (dir -> mkdir)