浏览代码

Fix MatchPoundUsingRegex "." not escaped bug (#373)

master
Lukas Zhang 5 年前
committed by Savorboard
父节点
当前提交
e2c257f960
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. +2
    -2
      src/DotNetCore.CAP/IConsumerServiceSelector.Default.cs

+ 2
- 2
src/DotNetCore.CAP/IConsumerServiceSelector.Default.cs 查看文件

@@ -195,7 +195,7 @@ namespace DotNetCore.CAP
.Where(x => x.Attribute.Name.IndexOf('#') >= 0)
.Select(x => new RegexExecuteDescriptor<ConsumerExecutorDescriptor>
{
Name = ("^" + x.Attribute.Name + "$").Replace("#", "[0-9_a-zA-Z\\.]+"),
Name = ("^" + x.Attribute.Name.Replace(".", "\\.") + "$").Replace("#", "[0-9_a-zA-Z\\.]+"),
Descriptor = x
}).ToList();
_poundList.TryAdd(group, tmpList);
@@ -220,4 +220,4 @@ namespace DotNetCore.CAP
public T Descriptor { get; set; }
}
}
}
}

正在加载...
取消
保存