make cache solve code work