Fixing nesting for image locations