Updating reference for use in web javascript