Moved location of where the cache is cleared to avoid clearing cache when reassessing application