it is fatal if left untreated but is common in rainbows and other fishes. Rainbowfish have soft bodies and bruise easily. So if you bought a second hand tank and took the fish out, emptied the tank and transported it to your house, then set it up, it was probably from that.
With rainbowfish, salt is the first line of defence. Just get a tablespoon and scoop out the salt and add it to the tank. It will sink to the bottom and dissolve over a few minutes and circulate through the water.
-------------------
Watch the rocks around the edge near the glass. Rainbows sometimes panic and can get caught between rocks and the glass and that can knock them about pretty badly. It's best to avoid sharp rocks completely.
-------------------
Make sure he gets plenty of plant matter in his diet. Rainbowfish do best when their diet consists of about half plant matter and half other foods like insects, small fish, shrimp, etc. They eat just about anything but I fed mine a goldfish flake and marine mix with mushed veges in it. Most days they got frozen or live daphnia, brineshrimp & mozzie larvae. I also had Duckweed on the surface all the time for them to graze on.