if (value instanceof TypeSafeValue<?>) {
throw new IllegalArgumentException(String.format("The value [%s] is already a type safe value.", value));
}
@SuppressWarnings("unchecked")
TypeSafeValue selectedValue = (TypeSafeValue) getRootQuery().dequeueSelectedValue();
if (selectedValue != null) {
return selectedValue;
}
List invocations = dequeueInvocations();
The dequeue of the invocation should happen also when selectedValue is actually a real value
The problem was actually that CaseTypeSafeValue was doing its own thing with invocation handling. Modified it to use the same logic as in the query instead here.
if (value instanceof TypeSafeValue<?>) { throw new IllegalArgumentException(String.format("The value [%s] is already a type safe value.", value)); } @SuppressWarnings("unchecked") TypeSafeValue selectedValue = (TypeSafeValue) getRootQuery().dequeueSelectedValue();
if (selectedValue != null) {
return selectedValue;
}
List invocations = dequeueInvocations();
The dequeue of the invocation should happen also when selectedValue is actually a real value
TSQB 3.0.0