Skip to content

Commit 161453e

Browse files
committed
fix: Check if pushNotification is the default value for gRPC in FromProto#pushNotificationConfig
1 parent ef6415a commit 161453e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

spec-grpc/src/main/java/io/a2a/grpc/utils/ProtoUtils.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -780,6 +780,9 @@ private static MessageSendConfiguration messageSendConfiguration(io.a2a.grpc.Sen
780780
}
781781

782782
private static PushNotificationConfig pushNotification(io.a2a.grpc.PushNotificationConfig pushNotification, String configId) {
783+
if (pushNotification == null || pushNotification.getDefaultInstanceForType().equals(pushNotification)) {
784+
return null;
785+
}
783786
return new PushNotificationConfig(
784787
pushNotification.getUrl(),
785788
pushNotification.getToken().isEmpty() ? null : pushNotification.getToken(),

0 commit comments

Comments
 (0)