1. Purchase only those than contain blue dye, to deter birdss, and a substance to make them taste nasty to hedgehogs (the packed will sometimes say this)
2. Only put them out when and where you have a slug problem, not "just in case".
3. Lay them inside pieces of pipe or under a low tunnel made of bricks, where hedgehogs cannot get at them. If you prop up a paving slab on small sticks or stones, to leave a 1 - 2 cm gap underneath, this shady retreat will attract slugs. Put in some smelly bait like fresh orange peel and they will come from far and wide. Here you can leave slug pellets safely, as birds and hedgehogs cannot squeeze into such a small space and the slugs will be killed out of reach.
4. Remove or bury and dead slugs you find.
5. You should consider an alternative method of slug destruction (e.g. slug traps baited with beer) You could also consider using an alternative chemical to kill slugs, but if the manufacturer has not tested it on hedgehogs, you are no better off than with conventional metaldehyde pellets and some of the alternatives are likely to be ineffective.
You could also think whether hedgehogs or lettuces are more important. You can buy the latter at the greengrocers.