update to javascript