corrected on demand sync bug