fix(TextPath): comparison is always false pathCmd === {}

This commit is contained in:
Nguyen Huu Kim 2022-08-09 09:56:00 +07:00
parent baf8780b26
commit 6f9c3fcbf9

View File

@ -306,7 +306,7 @@ export class TextPath extends Shape<TextPathConfig> {
}
}
if (pathCmd === {} || p0 === undefined) {
if (Object.keys(pathCmd).length === 0 || p0 === undefined) {
return undefined;
}