Code from our internal JavaScript OO training