fix newline on password bug
authorDavid Ascher <david@mozillamessaging.com>
Tue, 24 Feb 2009 16:49:14 -0800
changeset 54 e65d990ada6a8ff9bca749ec82b96d719c83344b
parent 53 5f05251057e9c4a418e7da9239d484e3f3111508
child 55 00899ecf7836eb505c757fca021b3c45a9b0fd6e
push id1
push userroot
push dateWed, 08 Apr 2009 01:46:05 +0000
fix newline on password bug
server/python/junius/bootstrap.py
--- a/server/python/junius/bootstrap.py
+++ b/server/python/junius/bootstrap.py
@@ -40,17 +40,17 @@ def setup_twitter_account(dbs):
     import os, os.path
     configPath = os.path.join(os.environ['HOME'], ".junius_twitter")
     if not os.path.isfile(configPath):
         print "Skipping twitter - no config file '%s'" % (configPath,)
         return
     f = open(configPath, 'r')
     data = f.read()
     f.close()
-    username, password = data.split(',')
+    username, password = data.strip().split(',')
 
     account = model.Account(
         kind='twitter', username=username, password=password,
     )
     account.store(dbs.accounts)
 
 def setup_skype_account(dbs):
     # For now we just use whoever is currently logged into skype (but we