Don't run actions set to 'null' or 'false'
This commit is contained in:
parent
07da88b7cb
commit
a3f423a1d6
1 changed files with 5 additions and 0 deletions
|
@ -70,7 +70,12 @@ export async function runAutomod(pluginData: PluginData<AutomodPluginType>, cont
|
||||||
|
|
||||||
if (matchResult) {
|
if (matchResult) {
|
||||||
for (const [actionName, actionConfig] of Object.entries(rule.actions)) {
|
for (const [actionName, actionConfig] of Object.entries(rule.actions)) {
|
||||||
|
if (actionConfig == null || actionConfig === false) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
const action = availableActions[actionName];
|
const action = availableActions[actionName];
|
||||||
|
|
||||||
action.apply({
|
action.apply({
|
||||||
ruleName,
|
ruleName,
|
||||||
pluginData,
|
pluginData,
|
||||||
|
|
Loading…
Add table
Reference in a new issue