Made javascript clean