Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Single Chapter Books - Allow book name without chapter / verse to resolve to whole book #22

Open
jpowell opened this issue Jan 6, 2022 · 0 comments

Comments

@jpowell
Copy link

jpowell commented Jan 6, 2022

I'd love for single chapter books to resolve just the same as a whole chapter reference. For example:

# nothing returned for this single chapter book
irb(main):020:0> Pericope.parse_one('Philemon')
=> nil
# full chapter verse range already handled for single chapter book WITHOUT chapter designation
irb(main):021:0> Pericope.parse_one('Philemon 1-25')
=> Pericope(Philemon 1–25)
irb(main):022:0> Pericope.parse_one('Ezekiel 1')
=> Pericope(Ezekiel 1)
# single chapter book could be similar to single chapter of multi chapter book
irb(main):023:0> Pericope.parse_one('Philemon 1-25').ranges
=> [57001001..57001025]
irb(main):024:0> Pericope.parse_one('Ezekiel 1').ranges
=> [26001001..26001028]

Right now we're handling this exception in a wrapper outside Pericope but would love if this was seen as a valid reference string. Thanks for the great library!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant