Oh bummer. Well that's hard to say how that would have affected the old motherboard or ram. Would assume motherboard/ram copped a short but since the stick was removed and not installed while there was power, you might've been lucky. What came of the old motherboard? Does it or the ram slot still work?
If ram is faulty because of what happened, it still wouldn't harm your new motherboard, just simply wont work.
You do know the differences between DDR 3 and 4 yeah? Just In case the older system is DDR 3 and your new motherboard uses DDR 4. That neither are interchangeable / psychically aren't compatible with one or other?