You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Calling getNode([ "top-dir", "nested-dir", "file" ]) will result in an error instead of returning null. Where "top-dir" exists, but "nested-dir" and "file" do not.
Given error:
Error: Cannot get node: Invalid WNFS path
The text was updated successfully, but these errors were encountered:
How do you suggest we go about it?
You could use a workaround by handling the error or we can introduce a variant of getNode that returns null with invalid paths.
Since get_node already returns a Result<Option<...>>, and that's Ok(None) if the last part of the path is missing, it should simply also return Ok(None) when any other path segment is missing.
Calling
getNode([ "top-dir", "nested-dir", "file" ])
will result in an error instead of returningnull
. Where "top-dir" exists, but "nested-dir" and "file" do not.Given error:
The text was updated successfully, but these errors were encountered: