You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// GetCasbinKey 根据key获取casbin
func (e *Application) GetCasbinKey(key string) casbin.SyncedEnforcer {
e.mux.Lock()
defer e.mux.Unlock()
if e, ok := e.casbins[""]; ok {
return e
}
return e.casbins[key]
}
// GetCasbinKey 根据key获取casbin
func (e *Application) GetCasbinKey(key string) casbin.SyncedEnforcer {
e.mux.Lock()
defer e.mux.Unlock()
if e, ok := e.casbins[""]; ok {
return e
}
return e.casbins[key]
}
建议这个方法把默认e.casbins["*"]去掉,因为我开发的场景用 可能还需要定制另外的xx_casbin_rule,
The text was updated successfully, but these errors were encountered: