Bug fixes for JS in records form not allowing to add/delete location and submit form