Path correction for the template