Skip to content

不能缓存没有参数的API请求吗? #32

@gaojinhsu

Description

@gaojinhsu

- (void)saveMemoryCacheWithResponse:(CTURLResponse *)response serviceIdentifier:(NSString *)serviceIdentifier methodName:(NSString *)methodName cacheTime:(NSTimeInterval)cacheTime { if (response.originRequestParams && response.content && serviceIdentifier && methodName) { [self.memoryCacheCenter saveCacheWithResponse:response key:[self keyWithServiceIdentifier:serviceIdentifier methodName:methodName requestParams:response.originRequestParams] cacheTime:cacheTime]; } }
请求没有参数时,originRequestParams为空就没办法缓存了。处于什么考虑呢?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions