Made a mistake in the javascript example