An attempt to clean up ajax code related to cache

It did not. Added a test.