Browse Source

Minor change.

pull/9239/head
maliming 5 years ago
parent
commit
a2497d5072
  1. 14
      framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Entities/Events/Distributed/AutoEntityDistributedEventSelectorListExtensions.cs

14
framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Entities/Events/Distributed/AutoEntityDistributedEventSelectorListExtensions.cs

@ -50,17 +50,17 @@ namespace Volo.Abp.Domain.Entities.Events.Distributed
); );
} }
public static bool Remove<TEntity>( /// <summary>
[NotNull] this IAutoEntityDistributedEventSelectorList selectors) where TEntity : IEntity /// Remove a specific entity type and the types derived from that entity type.
/// </summary>
/// <typeparam name="TEntity">Type of the entity</typeparam>
public static void Remove<TEntity>([NotNull] this IAutoEntityDistributedEventSelectorList selectors)
where TEntity : IEntity
{ {
Check.NotNull(selectors, nameof(selectors)); Check.NotNull(selectors, nameof(selectors));
var selectorName = "Entity:" + typeof(TEntity).FullName; var selectorName = "Entity:" + typeof(TEntity).FullName;
if (selectors.Any(s => s.Name == selectorName)) selectors.RemoveAll(s => s.Name == selectorName);
{
return selectors.RemoveAll(s => s.Name == selectorName).Count > 0;
}
return true;
} }
/// <summary> /// <summary>

Loading…
Cancel
Save