Skip to content

Commit 8b63e6a

Browse files
author
Šimon Šesták
committed
fix(observer-interceptor): Ensure stable request ID generation
Replaced `urlRequest.hashValue.description` with `ObjectIdentifier(request).debugDescription` for stable request tracking by observers, addressing potential inconsistencies with hash values.
1 parent e38a9cc commit 8b63e6a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Sources/GraphQLAPIKit/Interceptors/ObserverInterceptor.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ struct ObserverInterceptor<Observer: GraphQLNetworkObserver>: ApolloInterceptor
2828
return
2929
}
3030

31-
let requestId = urlRequest.hashValue.description
31+
let requestId = ObjectIdentifier(request).debugDescription
3232

3333
if response == nil {
3434
// BEFORE network fetch - call willSendRequest and store context synchronously

0 commit comments

Comments
 (0)