Fix errors found by TypeScript.  In particular, on lines 990 and 992 drawingCanvas should be canvas.  Why did this even work before?