Home Depot’s sales improved during its fiscal second quarter as customers spent more during the summer months and concentrated on smaller projects.