# HG changeset patch # User Elliott Sales de Andrade # Date 1300251556 0 # Node ID 380314aa5c1b464d295a068c6b2df78ec2fbc5be # Parent 0efc07144f2f83671c787f06488b4292e830df81 Fix some issues with purple-url-handler. The findaccount function was failing because the call to cpurple.PurpleAccountGetProtocolId used the wrong case for the function name. The IRC handler could also incorrectly called unquote_plus with a None value. I didn't really check the rest of the IRC handler, though. It might be broken in other ways. Reported by PotterT|VF in the IRC channel. diff -r 0efc07144f2f -r 380314aa5c1b ChangeLog --- a/ChangeLog Wed Mar 16 01:46:12 2011 +0000 +++ b/ChangeLog Wed Mar 16 04:59:16 2011 +0000 @@ -14,6 +14,7 @@ #13095) * Simple Silence Suppression is optional per-account. (Jakub Adam) (half of #13180) + * Fix purple-url-handler being unable to find an account. Pidgin: * Duplicate code cleanup. (Gabriel Schulhof) (#10599) diff -r 0efc07144f2f -r 380314aa5c1b libpurple/purple-url-handler --- a/libpurple/purple-url-handler Wed Mar 16 01:46:12 2011 +0000 +++ b/libpurple/purple-url-handler Wed Mar 16 04:59:16 2011 +0000 @@ -73,7 +73,7 @@ def findaccount(protocolname, accountname="", matcher=None): if matcher: for account in cpurple.PurpleAccountsGetAll(): - if (protocolname != cpurple.PurpleAccountGetProtocolID(account)) or \ + if (protocolname != cpurple.PurpleAccountGetProtocolId(account)) or \ (accountname != "" and accountname != cpurple.PurpleAccountGetUsername(account)): continue if matcher(account): @@ -188,7 +188,7 @@ print "Invalid irc URI: %s" % uri return - server = urllib.unquote_plus(match.group(2)) or "" + server = urllib.unquote_plus(match.group(2) or "") target = match.group(3) or "" query = match.group(5) or ""