Removing a trailing comma from the main javascript file