fix: cache bucket crash if memory limit is defined