Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[backend] Misuse function for workflow_id #6143

Merged
merged 1 commit into from
Feb 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion opencti-platform/opencti-graphql/src/database/engine.js
Original file line number Diff line number Diff line change
Expand Up @@ -2106,7 +2106,7 @@ const adaptFilterToWorkflowFilterKey = async (context, user, filter) => {
if (arrayKeys.length > 1) {
throw UnsupportedError(`A filter with these multiple keys is not supported : ${arrayKeys}`);
}
if (!arrayKeys[0].includes(WORKFLOW_FILTER, X_OPENCTI_WORKFLOW_ID)) {
if (![WORKFLOW_FILTER, X_OPENCTI_WORKFLOW_ID].includes(arrayKeys[0])) {
throw UnsupportedError('The key is not correct', { keys: arrayKeys });
}
if (operator === 'nil' || operator === 'not_nil') { // no status template <-> no status // at least a status template <-> at least a status
Expand Down
Loading