Skip to main content

validate_points

Function validate_points 

Source
pub fn validate_points(points: usize) -> Result<usize, Error>
Available on crate feature vcs-git only.
Expand description

Validate a requested point count against the MIN_TREND_POINTS / MAX_TREND_POINTS bounds. The single source of truth shared by every front end so the accepted range cannot drift between them.

ยงErrors

Returns Error::InvalidTrend when points is below the minimum or above the maximum.