ensure img.completed is set to true after successful load