vrt-ruby
vrt-ruby copied to clipboard
Let VRT::Map#find_node accept nil values
Description
Make VRT::Map#find_node
more durable to unexpected input
- Resolves: https://github.com/bugcrowd/vrt-ruby/issues/32
- Also adds some much needed spec coverage around
VRT::Map#find_node
Checklist:
- [x] I have made corresponding changes to the documentation
- [x] I have added tests that prove my fix is effective or that my feature works
- [x] I have added entries to CHANGELOG.md
- [x] I have not incremented
version.rb
@adamrdavid what do you think about putting this check in walk_tree
instead?
@maschwenk the error that get's raised when string is nil comes from string + max_depth
I have updated the readme to better describe the situation.
@adamrdavid I guess it makes no sense to try to cache invalid vrt_id
s so this is ok
At any rate this needs to be added to get_lineage
since that exhibits the same behavior of calling input + thing
. If you think of a better place to put the check let me know.