Using eval {} or do {} to catch errors is careless
Add 'if not exists'
Fix inadvertently reversed arguments
Typo: specify path in location {}