Fix for crash if no login token retrieved.

Change-Id: I63cd6b0910ab6d114abc5e061cac198a75d31110