Fixed login error, Added login check to createRequest