Automatic integration of company logo runs all my automations

Hello Guys !
I’ve set up this script founded on this forum !
My goal is to input the company logo automatically when the user puts the website url.
The problem is,
when the website’s url isn’t recognized, the automation keeps running and running and consumes all the automations :frowning:
What can I add to my script to stop the automation run after a minute for example (meaning that the website isn’t recognized) ?

Here is the script :
console.log(Hello, ${base.name}!);
let table = base.getTable(‘Expériences’);

let query = await table.selectRecordsAsync();

for (let record of query.records) {
// if the attachment field is empty
if(record.getCellValue(‘Logo’) == null && record.getCellValue(‘Site internet’) != null) {
let recordId = await table.updateRecordAsync(record, {
‘Logo’: [
{ url: ‘https://logo.clearbit.com/’+record.getCellValue('Site internet’)}
]
})
}
}

Thank for the help
Agathe