-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Description
isAuditsDisabled: disabled at org level for type is overruling enabled at site level for type
To Reproduce
Steps to reproduce the behavior:
Take an organization with config:
{
"config": {
"audits": {
"auditsDisabled": false,
"auditTypeConfigs": {
"organic-keywords": {
"disabled": true
},
"broken-backlinks": {
"disabled": true
},
"organic-traffic": {
"disabled": true
}
}
}
}
}
Take a site from the organization with auditConfig:
"auditConfig": {
"auditsDisabled": false,
"auditTypeConfigs": {
"organic-keywords": {
"disabled": true
},
"broken-backlinks": {
"disabled": false
},
"organic-traffic": {
"disabled": true
}
}
}
isAuditsDisabled(site, organization, 'broken-backlinks') returns true.
Expected behavior
Given an organization with config:
{
"config": {
"audits": {
"auditsDisabled": false,
"auditTypeConfigs": {
"organic-keywords": {
"disabled": true
},
"broken-backlinks": {
"disabled": true
},
"organic-traffic": {
"disabled": true
}
}
}
}
}
And a site from the organization with auditConfig:
"auditConfig": {
"auditsDisabled": false,
"auditTypeConfigs": {
"organic-keywords": {
"disabled": true
},
"broken-backlinks": {
"disabled": false
},
"organic-traffic": {
"disabled": true
}
}
}
isAuditsDisabled(site, organization, 'broken-backlinks') should return false.
Additional context
https://github.com/adobe/spacecat-shared/blob/main/packages/spacecat-shared-utils/src/helpers.js#L39
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working