😎优化雪花Id内存处理判断
This commit is contained in:
parent
e01e1989d4
commit
ec1baf2ecd
@ -22,7 +22,7 @@ public static class SqlSugarSetup
|
||||
{
|
||||
// 注册雪花Id
|
||||
var snowIdOpt = App.GetConfig<SnowIdOptions>("SnowId", true);
|
||||
if (App.GetConfig<CacheOptions>("Cache", true).CacheType == "Memory")
|
||||
if (App.GetConfig<CacheOptions>("Cache", true).CacheType == CacheTypeEnum.Memory.ToString())
|
||||
{
|
||||
YitIdHelper.SetIdGenerator(snowIdOpt);
|
||||
SnowFlakeSingle.WorkId = snowIdOpt.WorkerId;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user