Skip to content

Commit

Permalink
Merge pull request #187 from jszumski/pointer-mismatch
Browse files Browse the repository at this point in the history
Fix pointer type mismatch
  • Loading branch information
tcamin authored Sep 25, 2023
2 parents 5e9e82e + 73e5c55 commit 7fb89e1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions Sources/SBTUITestTunnelClient/SBTUITestTunnelClient.m
Original file line number Diff line number Diff line change
Expand Up @@ -338,12 +338,12 @@ - (BOOL)stubRequestsRemoveAll
if (objectBase64) {
NSData *objectData = [[NSData alloc] initWithBase64EncodedString:objectBase64 options:0];

NSDictionary *result = [NSKeyedUnarchiver unarchiveTopLevelObjectWithData:objectData error:nil];
return result ?: @{};
NSArray *result = [NSKeyedUnarchiver unarchiveTopLevelObjectWithData:objectData error:nil];

return result ?: @[];
}

return @{};
return @[];
}

#pragma mark - Rewrite Commands
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
/**
* Returns all active stubs
*
* @return A dictionary containing all active stubs
* @return An array containing all active stubs
*/
- (nonnull NSArray<SBTActiveStub *> *)stubRequestsAll;

Expand Down
2 changes: 1 addition & 1 deletion Sources/SBTUITestTunnelServer/SBTUITestTunnelServer.m
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ - (NSDictionary *)commandStubRequestsAll:(NSDictionary *)parameters
{
NSString *ret = nil;

NSDictionary *activeStubs = [SBTProxyURLProtocol stubRequestsAll];
NSArray *activeStubs = [SBTProxyURLProtocol stubRequestsAll];

NSData *data = [NSKeyedArchiver archivedDataWithRootObject:activeStubs requiringSecureCoding:NO error:nil];
if (data) {
Expand Down

0 comments on commit 7fb89e1

Please sign in to comment.