update to js sharing script