Fix error in rails cache