Permanent residency and divorce!!

A quick question for the immigration gurus here:
Can a permanent resident status be cancelled by the spouse after divorce? I know it can be revoked at anytime by immigration officials based on certain grounds, someone just told me that PR is only valid as long as you're married but if you get divorced your spouse can cancel it at anytime and they would give you a short period of time to leave the country!! Can someone shed some light on this?

Please note: US citizen here, been married for almost 1 year, not planning on getting divorced either, i possess the temp resident document, just needed to know what the law here says about such situation.
                             Thanks in advance!

You were advised correctly. In case of divorce your ex-wife can notify the immigration authorities and you will be asked to leave the country.