Little correction: it adds the background layer, but only if the new one is different than the previous one.