Made sync work with categories in path