testing sync, fixing some bugs for cache and added isEmpty underscore wrapper in util