Fix problems with / at the end of sync paths