Skip to content

Commit ae42da7

Browse files
thomaszurkan-optimizelyjaeopt
authored andcommitted
there was a checkin with the client using new instead of alloc. new in objective-c causes an alloc and init. then, init is called again with a builder parameter. this seems to be causing a crash. (#423)
1 parent 1de88a2 commit ae42da7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

OptimizelySDKShared/OptimizelySDKShared/OPTLYManagerBase.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ - (nonnull NSDictionary *)newDefaultAttributes {
215215
}
216216

217217
- (OPTLYClient *)initializeClientWithManagerSettingsAndDatafile:(NSData *)datafile {
218-
OPTLYClient *client = [[OPTLYClient new] initWithBuilder:[OPTLYClientBuilder builderWithBlock:^(OPTLYClientBuilder * _Nonnull builder) {
218+
OPTLYClient *client = [[OPTLYClient alloc] initWithBuilder:[OPTLYClientBuilder builderWithBlock:^(OPTLYClientBuilder * _Nonnull builder) {
219219
builder.datafile = datafile;
220220
builder.errorHandler = self.errorHandler;
221221
builder.eventDispatcher = self.eventDispatcher;

0 commit comments

Comments
 (0)