Skip to content

Commit

Permalink
rename func
Browse files Browse the repository at this point in the history
  • Loading branch information
justvanrossum committed Nov 25, 2023
1 parent cf45004 commit a68c683
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/fontra/client/core/discrete-variation-model.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ function splitDiscreteLocation(location, discreteAxes) {
delete location[axis.name];
if (axis.values.indexOf(value) < 0) {
// Ensure the value is actually in the values list
value = findNearest(value, axis.values);
value = findNearestValue(value, axis.values);
}
} else {
value = axis.defaultValue;
Expand All @@ -98,7 +98,7 @@ function splitDiscreteLocation(location, discreteAxes) {
return { discreteLocation, location };
}

function findNearest(value, values) {
function findNearestValue(value, values) {
if (!values.length) {
return value;
}
Expand Down

0 comments on commit a68c683

Please sign in to comment.