store user to the global window obj