All files / internalHelpers _guard.js

100% Statements 1/1
100% Branches 0/0
100% Functions 1/1
100% Lines 1/1
1 2 3 4 5 6 7 8      35x        
// @flow
 
function guard(lowerBoundary: number, upperBoundary: number, value: number): number {
  return Math.max(lowerBoundary, Math.min(upperBoundary, value))
}
 
export default guard