Added convenience function.
This commit is contained in:
parent
0e6f640554
commit
6ce1662497
1 changed files with 10 additions and 0 deletions
|
|
@ -1,5 +1,7 @@
|
|||
package bible
|
||||
|
||||
import "strings"
|
||||
|
||||
var singleChapters = map[string]struct{}{
|
||||
"oba": {},
|
||||
"2jn": {},
|
||||
|
|
@ -7,3 +9,11 @@ var singleChapters = map[string]struct{}{
|
|||
"phm": {},
|
||||
"jud": {},
|
||||
}
|
||||
|
||||
func HasSingleChapter(book string) bool {
|
||||
book = strings.ToLower(book)
|
||||
if _, ok := singleChapters[book]; ok {
|
||||
return true
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue