fix naming and bug that made js not fire until refreshed.