fix cache type bug