Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

@implementation {{classPrefix}}Configuration

#pragma mark - Singletion Methods
#pragma mark - Singleton Methods

+ (instancetype) sharedConfig {
static {{classPrefix}}Configuration *shardConfig = nil;
Expand All @@ -35,6 +35,7 @@
self.mutableApiKey = [NSMutableDictionary dictionary];
self.mutableApiKeyPrefix = [NSMutableDictionary dictionary];
self.mutableDefaultHeaders = [NSMutableDictionary dictionary];
self.mutableDefaultHeaders[@"User-Agent"] = {{#httpUserAgent}}@"{{httpUserAgent}}"{{/httpUserAgent}}{{^httpUserAgent}}[NSString stringWithFormat:@"Swagger-Codegen/{{version}}/objc (%@; iOS %@; Scale/%0.2f)",[[UIDevice currentDevice] model], [[UIDevice currentDevice] systemVersion], [[UIScreen mainScreen] scale]]{{/httpUserAgent}};
self.logger = [{{classPrefix}}Logger sharedLogger];
}
return self;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ @interface SWGConfiguration ()

@implementation SWGConfiguration

#pragma mark - Singletion Methods
#pragma mark - Singleton Methods

+ (instancetype) sharedConfig {
static SWGConfiguration *shardConfig = nil;
Expand All @@ -35,6 +35,7 @@ - (instancetype) init {
self.mutableApiKey = [NSMutableDictionary dictionary];
self.mutableApiKeyPrefix = [NSMutableDictionary dictionary];
self.mutableDefaultHeaders = [NSMutableDictionary dictionary];
self.mutableDefaultHeaders[@"User-Agent"] = [NSString stringWithFormat:@"Swagger-Codegen/1.0.0/objc (%@; iOS %@; Scale/%0.2f)",[[UIDevice currentDevice] model], [[UIDevice currentDevice] systemVersion], [[UIScreen mainScreen] scale]];
self.logger = [SWGLogger sharedLogger];
}
return self;
Expand Down