GetAllRulesConfigs gets the rules configs for all users that have them.
(ctx context.Context)
| 118 | |
| 119 | // GetAllRulesConfigs gets the rules configs for all users that have them. |
| 120 | func (d *DB) GetAllRulesConfigs(ctx context.Context) (map[string]userconfig.VersionedRulesConfig, error) { |
| 121 | cfgs := map[string]userconfig.VersionedRulesConfig{} |
| 122 | for user, c := range d.cfgs { |
| 123 | cfg := c.GetVersionedRulesConfig() |
| 124 | if cfg != nil { |
| 125 | cfgs[user] = *cfg |
| 126 | } |
| 127 | } |
| 128 | return cfgs, nil |
| 129 | } |
| 130 | |
| 131 | // GetRulesConfigs gets the rules configs that have changed |
| 132 | // since the given config version. |
nothing calls this directly
no test coverage detected