Update canvas2image.js

Cosmetics :

remove ending-spaces