diff --git a/CHANGELOG.md b/CHANGELOG.md index d86bf9580..f94a536bf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,14 @@ All notable changes to this project will be documented in this file. Take a look **Warning:** Features marked as *alpha* may change or be removed in a future release without notice. Use with caution. - +## [Unreleased] + +### Fixed + +#### Shared + +* [#444](https://github.com/readium/swift-toolkit/issues/444) Fixed resolving titles of search results when the table of contents items contain fragment identifiers. + ## [2.7.1] diff --git a/Sources/Internal/Extensions/String.swift b/Sources/Internal/Extensions/String.swift index 1f9609c87..36457aabe 100644 --- a/Sources/Internal/Extensions/String.swift +++ b/Sources/Internal/Extensions/String.swift @@ -67,7 +67,7 @@ public extension String { guard let range = range(of: delimiter, options: [.backwards, .literal]) else { return self } - return String(self[...range.lowerBound]) + return String(self[..