Fixed bugs with cache commands