Things don't usually fail mysteriously. There's normally an explanation or at least a couple of possibilities that you should check out before you go and do the same thing again, such as:
1. Neglect/abuse. Was the chain lubed frequently or did anything ever get stuck between the chain and sprockets and stretch the piss out of the chain?
2. Was chain slack adjusted properly?
3. Were the chain/sprockets aligned?
4. Was the swingarm pivot bolt tight? This will affect both 2 and 3 above. Note that a loose swingarm bolt is a common problem on these bikes that leads to a wallowed out bolt hole. The bolt needs to be checked religiously.
5. Were the chain and sprockets being used beyond there expected life, i.e., worn to excess?
6. Quality problem. Pretty rare these days with modern manufacturing and quality control, but I stay away from stuff made in China if I can and will pay an extra $10-$20 if that's what it takes to get a quality part.
7. Other. I'm bound to be missing something.
You may not be able to tell if items 1-3 were a factor now that the chain is busted, but your
maintenance practices (or lack of) should give you a clue.
Good luck and let us know what you find out so we all can learn.