How did the ghana empire end?

1. Almoravids from northwest africa invaded, disrupting the empire
2. Poor leadership resulted in loss of control of gao and then the rest of the empire
3. soldiers from morocco invaded and overpowered

the Ghana Empire, leading to its collapse.