fixed cache bug (which caused crash on update operation)