Remove hibernate from the log-off menu in Ubuntu

I have had little success getting the hibernate feature to work on any Laptop running Ubuntu. I currently use a Dell XPS with 6 Gigs of RAM and don’t even find it practical to hibernate due to the waste on hard drive space and the time it takes to go down and come back up. With a good battery it is much easier to suspend. I don’t even like having the hibernate option on the menu for fear of an accidental click. So I finally got around to figuring out how to get it off the menu and I thought I would pass it on for anyone wanting to do the same.

All you need to do to remove hibernate from the menu is to change allow_active to no under the org.freedesktop.upower.hibernate section of the file /usr/share/polkit-1/actions/org.freedesktop.upower.policy. To do this open a terminal and type:
sudo gedit /usr/share/polkit-1/actions/org.freedesktop.upower.policy
Find the line below the org.freedesktop.upower.hibernate section that says:

<allow_active>yes</allow_active>

and change it to:

<allow_active>no</allow_active>

Save the file and restart the indicator-session service with the following command:
killall indicator-session-service

Your done!