diff --git a/src/bezpath.rs b/src/bezpath.rs index edd57cdb..e9462ffe 100644 --- a/src/bezpath.rs +++ b/src/bezpath.rs @@ -193,7 +193,7 @@ impl BezPath { /// ``` pub fn from_vec(v: Vec) -> BezPath { debug_assert!( - v.first().is_none() || matches!(v.first(), Some(PathEl::MoveTo(_))), + v.is_empty() || matches!(v.first(), Some(PathEl::MoveTo(_))), "BezPath must begin with MoveTo" ); BezPath(v)