Ask the user to login to Facebook when we get a bad password response. Fixes #15583
authorFrank Dowsett <wixardy@adium.im>
Sun, 30 Oct 2011 13:35:26 -0400
changeset 3647 af8314033d64
parent 3646 209a3186ccb7
child 3648 3d0680a6d02c
Ask the user to login to Facebook when we get a bad password response. Fixes #15583
(transplanted from 2d15405b6d7163cd6b8955c8fb88cbbde941788f)
Plugins/Purple Service/AIFacebookXMPPAccount.m
--- a/Plugins/Purple Service/AIFacebookXMPPAccount.m	Sun Oct 30 19:49:53 2011 +0100
+++ b/Plugins/Purple Service/AIFacebookXMPPAccount.m	Sun Oct 30 13:35:26 2011 -0400
@@ -203,13 +203,17 @@
 		[self requestFacebookAuthorization];
 
 	} else {
+		[self setValue:nil
+		   forProperty:@"mustPromptForPasswordOnNextConnect"
+				notify:NotifyNever];
 		[super passwordReturnedForConnect:inPassword returnCode:returnCode context:inContext];
 	}
 }
 
 - (void)retrievePasswordThenConnect
 {
-	if ([self boolValueForProperty:@"Prompt For Password On Next Connect"]) 
+	if ([self boolValueForProperty:@"Prompt For Password On Next Connect"] ||
+		[self boolValueForProperty:@"mustPromptForPasswordOnNextConnect"])
 		/* We attempted to connect, but we had incorrect authorization. Display our auth request window. */
 		[self requestFacebookAuthorization];