Skip to content

Commit 4194dce

Browse files
committed
Fix typo in variable name for squared line length in _line_project_helper in src_c/line.c
1 parent 2401414 commit 4194dce

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src_c/line.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,14 +227,14 @@ _line_project_helper(pgLineBase *line, double *point, int clamp)
227227
double squared_line_length =
228228
line_vector[0] * line_vector[0] + line_vector[1] * line_vector[1];
229229

230-
if (squred_line_length == 0.0 && clamp) {
230+
if (squared_line_length == 0.0 && clamp) {
231231
double projected_point[2];
232232
projected_point[0] = line->ax;
233233
projected_point[1] = line->ay;
234234
return pg_tuple_couple_from_values_double(projected_point[0],
235235
projected_point[1]);
236236
}
237-
else if (squred_line_length == 0.0) {
237+
else if (squared_line_length == 0.0) {
238238
return RAISE(PyExc_ValueError,
239239
"The Line has to have some length or this method has to "
240240
"be clamped to work");

0 commit comments

Comments
 (0)