Skip to content

Commit a510c17

Browse files
committed
chore: refactor
1 parent df6ac47 commit a510c17

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Diff for: src/canvas.ios.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -1104,8 +1104,10 @@ export class Paint implements IPaint {
11041104
set color(color: Color | number | string) {
11051105
if (color instanceof Color) {
11061106
this._color = color;
1107+
} else if (!!color){
1108+
this._color = new Color(color as any);
11071109
} else {
1108-
this._color = !!color ? new Color(color as any) : null;
1110+
this._color = undefined;
11091111
}
11101112
}
11111113
setColor(color: Color | number | string) {

0 commit comments

Comments
 (0)