Apply style guide rules to the remaining classes

This commit is contained in:
Sergey Abramchuk
2018-01-23 17:04:32 +03:00
parent c682c2a325
commit badd6d28be
17 changed files with 43 additions and 40 deletions
+3 -2
View File
@@ -6,6 +6,7 @@
//
//
#import "OpenVPNSessionToken.h"
#import "OpenVPNSessionToken+Internal.h"
using namespace openvpn;
@@ -18,7 +19,7 @@ using namespace openvpn;
@implementation OpenVPNSessionToken
- (instancetype)initWithSessionToken:(ClientAPI::SessionToken)token {
if ((self = [super init])) {
if (self = [super init]) {
self.username = !token.username.empty() ? [NSString stringWithUTF8String:token.username.c_str()] : nil;
self.session = !token.session_id.empty() ? [NSString stringWithUTF8String:token.session_id.c_str()] : nil;
}
@@ -38,7 +39,7 @@ using namespace openvpn;
}
- (nullable instancetype)initWithCoder:(nonnull NSCoder *)aDecoder {
if ((self = [self init])) {
if (self = [self init]) {
self.username = [aDecoder decodeObjectOfClass:[NSString class] forKey:NSStringFromSelector(@selector(username))];
self.session = [aDecoder decodeObjectOfClass:[NSString class] forKey:NSStringFromSelector(@selector(session))];
}