Document that optional() requires import of rusqlite::OptionalExtension

Document that `optional()` requires import of `rusqlite::OptionalExtension`.
This commit is contained in:
kud1ing 2020-11-10 15:12:04 +01:00 committed by Thom Chiovoloni
parent 248db0350d
commit 7beba0c6eb

View File

@ -438,7 +438,8 @@ impl Statement<'_> {
///
/// Returns `Err(QueryReturnedNoRows)` if no results are returned. If the
/// query truly is optional, you can call `.optional()` on the result of
/// this to get a `Result<Option<T>>`.
/// this to get a `Result<Option<T>>` (requires that the trait `rusqlite::OptionalExtension`
/// is imported).
///
/// # Failure
///
@ -464,7 +465,8 @@ impl Statement<'_> {
///
/// Returns `Err(QueryReturnedNoRows)` if no results are returned. If the
/// query truly is optional, you can call `.optional()` on the result of
/// this to get a `Result<Option<T>>`.
/// this to get a `Result<Option<T>>` (requires that the trait `rusqlite::OptionalExtension`
/// is imported).
///
/// # Failure
///