Modified root variable so path is dynamically generated