We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f925694 commit 5d20127Copy full SHA for 5d20127
static/js/rules/RuleUtils.js
@@ -30,9 +30,16 @@ const RuleUtils = {
30
console.warn('byProperty property undefined', new Error().stack);
31
return false;
32
}
33
-
+ const propHref = `/things/${encodeURIComponent(property.thing)}/properties/${encodeURIComponent(
34
+ property.id
35
+ )}`;
36
const optProp = option.properties[property.id];
- return optProp && optProp.forms && optProp.forms.length;
37
+ return (
38
+ optProp &&
39
+ optProp.forms.filter((f) => {
40
+ return f.href === propHref;
41
+ }).length > 0
42
+ );
43
},
44
// Helper function for selecting the thing corresponding to an href
45
byThing: (thing) => (otherThing) => {
0 commit comments