Reading List
UserDefaults.register(defaults:) Footgun from Michael Tsai RSS feed.
UserDefaults.register(defaults:) Footgun
Jeff Johnson (Mastodon): “Every instance of UserDefaults shares the contents of the argument and registration domains.” In other words, the result of calling registerDefaults on the object returned by [NSUserDefaults initWithSuiteName:] is the same as calling registerDefaults on the object returned by [NSUserDefaults standardUserDefaults]! Yet the documentation for registerDefaults does not mention this fact. How […]