Add a null check

In theory night prevent the NPE on v500 when trying enable/disbale autorotate
http://pastebin.com/LAPVgsp8

Change-Id: I550cb570042855e4b9bc85bb1e8ef2ada702a7dc