2026-10-14 19:09:34 +02:00
|
|
|
//! Error adapters: the libraries each have their own error type.
|
|
|
|
|
|
|
|
|
|
use anyhow::{Result, anyhow};
|
|
|
|
|
|
|
|
|
|
pub fn sk<T>(r: obiskio::SKResult<T>) -> Result<T> {
|
|
|
|
|
r.map_err(|e| anyhow!("{e}"))
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
pub fn oki<T>(r: obikindex::OKIResult<T>) -> Result<T> {
|
|
|
|
|
r.map_err(|e| anyhow!("{e}"))
|
|
|
|
|
}
|