RELATIONS.md - access relation Id #749
-
The current documentation RELATIONS.md states : You can obtain the relation ID and role from But I've realized that under the node_function (I haven't tried with the way_function), I actually access the relation Id via if you do:
you will get the relation Id. Am I doing anything wrong ? Or is there really a typo in the doc ? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
I think you're right -- the docs are incorrect. The docs might read better as: You can also obtain the element's role in the relation at the same time, via a second return value: local rel, role = NextRelation()
if not rel then break end |
Beta Was this translation helpful? Give feedback.
I think you're right -- the docs are incorrect.
NextRelation()
returns two return values, not a single return value that is an array with two values.The docs might read better as:
You can also obtain the element's role in the relation at the same time, via a second return value: