I believe it used to be whichever was added to the hero most recently, not sure if it's changed or not.