themetalfleece / neogma

Object-Graph-Mapping neo4j framework, Fully-typed with TypeScript, for easy and flexible node and relationship operations
https://themetalfleece.github.io/neogma/
MIT License
122 stars 12 forks source link

Bug: Infinity max hops improperly working #72

Closed tomek7667 closed 1 year ago

tomek7667 commented 1 year ago
            /* --> (optional) minimum hops for a variable length relationship */
            minHops: 1,
            /* --> (optional) maximum hops for a variable length relationship. The value Infinity can be used for no limit on the max hops */
            maxHops: 1,

The comment stating that value Infinity will be no limit for the recursion is not accurate. When entered 9999999 working perfectly fine, when entered Infinity works like for a 1 hop.

themetalfleece commented 1 year ago

Hello, using Infinity generates a [*] relationship which matches 1 or more iterations. So, is [*] used in the generated cypher but doesn't work as expected?

tomek7667 commented 1 year ago

I see, I think that I misunderstood the feature, sorry for the trouble

themetalfleece commented 1 year ago

No worries. In the meantime I found out a bug when only minHops is passed, I'll create a fix soon.