fixed caching logic, still need to test for serverside filtering