Habitat effects on the relative importance of trait- and density-mediated indirect interactions.