Skip to main content

fs_not_enabled

Function fs_not_enabled 

Source
pub fn fs_not_enabled() -> Response
Expand description

The refusal sent when no --fs-root was configured.

A function rather than a Result-returning guard: handlers return Response directly, so ? never applies and a Result buys nothing — it only makes the error variant large enough to trip clippy::result_large_err, which invites boxing a problem that need not exist. Callers pair this with let Some(root) = state.fs.clone() else { return fs_not_enabled(); }.