There is an interesting story in Dattatreya Mahatmya about
Lord Dattatreya defeating demons with the help of Goddess Lakshmi. Demon army
led by demon king Jambha defeated the Devas or demigods. He became the ruler of
the three worlds.
On the advice of Brihaspati, the gods went to the hermitage
of Dattatreya and asked for his help.
Goddess Lakshmi was living in the hermitage of Dattatreya
during the time.
They promised to help the Devas.
A plan was hatched and as per the plan, Devas were to get
the demons to the ashram of Dattatreya.
As per the plan, Devas attacked the demons. When the demons
retaliated, the Devas took refuge in the ashram of Dattatreya.
Demons soon reached the ashram. However, when they saw the beautiful
goddess Lakshmi by the side of Dattatreya they were filled with passion. They
decided to kidnap her.
Dattatreya then told the Devas that due to the immoral
behavior of the demons they have lost their prowess and strength.
On hearing this Devas attacked the demons and defeated them.