Fix wrong cache keys and cache check

- Wrong cache keys was handed to the setter
- Only try to get cache which exists