In 1163, Shirkuh led an invasion of the Fatimid Caliphate, which controlled Egypt. After this first attack, Shirkuh's Zengid army went out of Egypt in 1164, but they attacked again in 1167. This invasion had success, but after two years Shirkuh died. The son of Najm ad-Din Ayyub then took control of his uncle Shirkuh's army in Egypt. This son was Salah ad-Din Yusuf ibn Ayyub ("Saladin"). Working for Nur ad-Din Zengi, Saladin then used the Zengid army for the destruction of the Fatimid Caliphate. Doing this, Saladin ended the control of Shia Islam in Egypt and took control of Egypt himself when Nur ad-Din died in 1174.