Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
kostapetan committed Nov 23, 2024
1 parent 985b165 commit ae4cb9b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dotnet/src/Microsoft.AutoGen/Agents/AgentBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -224,9 +224,9 @@ static async ((AgentBase Agent, CloudEvent Event) state) =>
public Task CallHandler(CloudEvent item)
{
// Only send the event to the handler if the agent type is handling that type
// foreach of the keys in the EventTypes.EventsMap[] if it contains the item.type

foreach (var type in EventTypes.TypesMap[item.Type])
if (EventTypes.EventsMap[GetType()].Contains(item.Type) &&
item.Source == AgentId.Key)
{
var payload = item.ProtoData.Unpack(EventTypes.TypeRegistry);
var convertedPayload = Convert.ChangeType(payload, EventTypes.Types[item.Type]);
Expand Down

0 comments on commit ae4cb9b

Please sign in to comment.