New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix cli for compatibility with xcodeproj 1.0.0 #10
base: develop
Are you sure you want to change the base?
Conversation
|
||
/// String description of the enum value | ||
public var description: String { | ||
guard let value = Self.get(self) else { return "nil" } | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)
|
||
Settings.subscribe(.EnableAnalytics) { (newValue) -> Void in | ||
Settings.subscribe(setting: .EnableAnalytics) { (newValue) -> Void in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unused Closure Parameter Violation: Unused parameter "newValue" in a closure should be replaced with _. (unused_closure_parameter)
|
||
let result = Settings.get(.ApiEnvironment) as! String | ||
let result = Settings.get(setting: .ApiEnvironment) as! String |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Force Cast Violation: Force casts should be avoided. (force_cast)
|
||
let result = Settings.get(.LuckyNumber) as! Int | ||
let result = Settings.get(setting: .LuckyNumber) as! Int |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Force Cast Violation: Force casts should be avoided. (force_cast)
|
||
let result = Settings.get(.CityState) as! [ String: String ] | ||
let result = Settings.get(setting: .CityState) as! [ String: String ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Force Cast Violation: Force casts should be avoided. (force_cast)
|
||
let result = Settings.get(.DateOfBirth) as! NSDate | ||
let result = Settings.get(setting: .DateOfBirth) as! NSDate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Force Cast Violation: Force casts should be avoided. (force_cast)
|
||
let result = NSUserDefaults.standardUserDefaults().objectForKey(identifier) as! NSDate | ||
let result = UserDefaults.standard.object(forKey: identifier) as! NSDate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Force Cast Violation: Force casts should be avoided. (force_cast)
|
||
let result = NSUserDefaults.standardUserDefaults().objectForKey(identifier) as! NSData | ||
let result = UserDefaults.standard.object(forKey: identifier) as! NSData |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Force Cast Violation: Force casts should be avoided. (force_cast)
|
||
expect(result) == value | ||
} | ||
|
||
it("can store data") { | ||
let identifier = Settings.EncodedString.identifier | ||
let value = NSData(base64EncodedString: "SGVsbG8gV29ybGQ=", options: []) as NSData! | ||
let value = NSData(base64Encoded: "SGVsbG8gV29ybGQ=", options: []) as! NSData |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Force Cast Violation: Force casts should be avoided. (force_cast)
|
||
let result = NSUserDefaults.standardUserDefaults().arrayForKey(identifier) as! [String] | ||
let result = UserDefaults.standard.array(forKey: identifier) as! [String] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Force Cast Violation: Force casts should be avoided. (force_cast)
center.addObserverForName(NSUserDefaultsDidChangeNotification, object: defaults, queue: nil) { (notif) -> Void in | ||
if let defaults = notif.object as? NSUserDefaults { | ||
onChange(newValue: defaults.objectForKey(self.identifier)) | ||
center.addObserver(forName: UserDefaults.didChangeNotification, object: defaults, queue: nil) { (notif) -> Void in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Discarded Notification Center Observer Violation: When registering for a notification using a block, the opaque observer that is returned should be stored so it can be removed later. (discarded_notification_center_observer)
In version 1.0.0 of gem
xcodeproj
the modulePlistHelper
no longer exists and it has been replaced byPlist