correctly catch invalid login message on api call. fix project upload after
session refresh.