Skip to content

Commit 65f4bad

Browse files
committed
Simpler rules to match hypothesis and lois
1 parent f699bfb commit 65f4bad

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

server/src/main/java/org/diskproject/server/repository/DiskRepository.java

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1032,7 +1032,7 @@ public Set<String> interceptVariables(final String queryA, final String queryB)
10321032
*/
10331033

10341034
private Boolean isValid(LineOfInquiry loi) {
1035-
// Mandatory fields for Lines of Inquiry
1035+
// Mandatory fields for Lnes of Inquiry
10361036
String hq = loi.getHypothesisQuery();
10371037
if (hq == null || hq.equals(""))
10381038
return false;
@@ -1067,8 +1067,6 @@ private Boolean isValid(LineOfInquiry loi, Map<String, String> hypothesisBinding
10671067
// All variables used on both, the hypothesis query and data query, must have
10681068
// valid values in this point.
10691069
Set<String> inVars = interceptVariables(loi.getHypothesisQuery(), dataQuery);
1070-
if (inVars.size() == 0)
1071-
return false;
10721070
for (String variable : inVars) {
10731071
if (!hypothesisBindings.containsKey(variable.substring(1)))
10741072
return false;
@@ -1080,11 +1078,6 @@ private Boolean isValid(LineOfInquiry loi, Map<String, String> hypothesisBinding
10801078
List<String> varList = wb.getAllVariables();
10811079
if (varList.size() == 0)
10821080
return false;
1083-
// This varName is the binding of the workflow, can be an special string too so this was disabled.
1084-
//for (String varName : varList) {
1085-
// if (!(hypothesisBindings.containsKey(varName.substring(1)) || dataQuery.contains(varName) ))
1086-
// return false;
1087-
//}
10881081
}
10891082
return true;
10901083
}

0 commit comments

Comments
 (0)