DETROIT — Taking her cue from a minister who praised her public grace "in the face of adversity," an apparent reference to former president Bill Clinton's dalliance with an intern, Hillary Clinton likened her husband to the prodigal son in the often-cited Bible story.

“What has always guided me and supported me has been my faith, has been my belief in the saving graces, and the salvation that faith brings," Clinton said Sunday during a visit to an African American church here. "And in those difficult times in my life, I have often been struck by a particular passage from scripture," Clinton said, before recounting the story of the son who abandons and disrespects his father but is forgiven and welcomed home.

“When someone has disappointed you, has often disappointed themselves, it is human nature to say: 'You’re not wanted. We know what you’ve been doing. Go sleep in the bed you made,'" Clinton said.

"But this isn’t what the father in this parable" does, she said.

She reminded the congregants at the Holy Ghost Cathedral that he instead put on his finest clothes, had the cooks prepare a feast and went out to meet his returning son with an embrace.

Clinton said she took from that parable the need to “practice the discipline of gratitude every day. There is much to be grateful for even when it doesn’t feel or look like it.”

It was a rare allusion to that painful and humiliating period for Clinton. She did not elaborate or speak directly about the details of her husband's acknowledged infidelity, but the context was clear.

In introducing Clinton, the church pastor, Bishop Corletta J. Vaughn, said Clinton showed women how to "take a licking and keep on ticking‎."

"I'm talking as a wife and a mother," Vaughn said. "She taught so many of us as women how to stand in the face of adversity."

Clinton said she "appreciated" the pastor's reference to "storms and troubles, but every one of us could stand and tell our story."

She noted that the prodigal son parable “is also about Our Father in heaven who is always ready to take us back …who gave His only begotten son for us. So practicing the discipline of gratitude is one of the ways we understand more what is expected of us.”

“How hard it must have been for both the father and the older brother when the prodigal son came home," Clinton said. The younger son, after all, had "been out there having a pretty good time committing every sin that you could list.”

Clinton visited three black churches Sunday, before a debate in Flint, Mich., that will highlight a poisoned-water crisis in the majority-black city.