If it works, it works. There really is no way of knowing if the internals were exposed to water short of someone taking it apart (if it was done properly, it should also include a complete replacement of the adhesive seals that provide the water resistance) and then checking all the liquid contact indictors, and/or examining it for signs of liquid damage. These are little devices inside an iPhone that will change to reddish pink if exposed to liquid water. There is one that's easy to determine, which is just inside the SIM card slot.
Water and other liquid damage to iPhone or iPod isn't covered by warranty - Apple Support

Even then, simply because there was liquid water doesn't mean there was damage. However, the LCI turning will generally render a device unfit (according to Apple) for any kind of repair service other than a full replacement. Not even a battery or front screen assembly replacement, regardless of whether or not there's actual damage to the electronics.
Another thing to consider is that even if the seals keep out water from entering inside once, they may degrade after exposure to water where they could shrink/dry out. The seals will eventually degrade anyways.