1
0
Fork 0

[client] Only render the pencil if it actually exists

This commit is contained in:
Starbeamrainbowlabs 2017-04-16 16:18:45 +01:00
parent ec5f7e0bd9
commit 4a55f7a941
1 changed files with 3 additions and 1 deletions

View File

@ -178,7 +178,9 @@ class BoardWindow extends EventEmitter
context.clearRect(0, 0, canvas.width, canvas.height); context.clearRect(0, 0, canvas.width, canvas.height);
this.renderOthers(canvas, context); this.renderOthers(canvas, context);
this.pencil.render(canvas, context); // Render the currently active line
if(typeof this.pencil !== "undefined")
this.pencil.render(canvas, context);
} }
renderOthers(canvas, context) renderOthers(canvas, context)