Skip to content

两块不同的缓存,数据粘连 #10

@hanchenhao

Description

@hanchenhao
        let cache: Cache = Cache.shareInstance
        cache.set(object: "2222" as NSCoding, forKey: "2223")
        let cache2 = Cache(name: "cache2")

        cache2?.set(object: "1111" as NSCoding, forKey: "1111")
        print(cache.object(forKey: "1111") ?? "none")

输入结果为:1111

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