function setAddress() {
fetch('https://ipinfo.io/json')
.then(response => response.json())
.then(data => {
console.log(data);
jQuery('input[name="lead[city]"]').val(data?.city ?? '');
jQuery('input[name="lead[state]"]').val(data?.region ?? '');
jQuery('input[name="lead[zipcode]"]').val(data?.postal ?? '');
jQuery('input[name="lead[country]"]').val(data?.country ?? '');
});
}
setTimeout(setAddress, 6000);