STAY CALM! You may be able to save it!
First you will flush the toilet to drain the water and remove the phone when the water level is at a minimum.
If the phone is already shut off, you're doomed :(. The phone already shorted out.
If the phone is still on, power off immediately!!! The assure the phone will not short out.
If weather is nice, you can allow your phone to catch some rays of sun and dry out. You may also wrap it in a towel with rope to secure it in and stick it in the dryer. DO NOT STICK IT IN THE MICROWAVE! Believe me.... I've done it.
Once completely dry and phone still off, cleanse/drench your phone in hand sanitizer and wait until completely dry to power on.