crazy cache clearing code