Fixing all docblocks and generating documentation with jsDoc3
Fixing a reference error