Change dir struct and logic