how to avoid foundation problems