The workflow step expression doesn't put the resulting string between brackets, this could lead to problems such as:
Expression cTypeExpr = new ContentTypeExpression(Operator.EQ, "news"); Expression stepsExpr = new WorkflowStepExpression(Operator.EQ, new int[] {1, 2}, LogicalOperator.OR); new AndExpression(cTypeExpr, stepsExpr).build(); // (@ametys-internal:contentType = 'news' and @ametys-internal:currentStepId =1 or @ametys-internal:currentStepId =2)
-> "All the news in draft state OR all the contents in proposed state, whatever their content type", because the AND operator has more priority than the OR operator.