Fix closure compiler bug with cache trim method.