I usually change what DD2 is saying if she accidentally hears something she isn't meant to

I say "oh you mean 'For Pete's Sake' or 'Farrr Out'" etc.. eventually she replaces the swear work with the not so bad one.
Yep, that works well.