From b9d3e87fdada8ecec8218498b3490daf48c74d70 Mon Sep 17 00:00:00 2001 From: Vincent Paredes Date: Tue, 4 Nov 2014 14:21:53 +0100 Subject: [PATCH] fixing using new account page version when we are already on old account page --- modules/paypal/browser.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/modules/paypal/browser.py b/modules/paypal/browser.py index ca682225..ebf84110 100644 --- a/modules/paypal/browser.py +++ b/modules/paypal/browser.py @@ -81,16 +81,18 @@ class Paypal(Browser): def get_accounts(self): self.find_website_version() - if self.website == "old" and not self.is_on_page(AccountPage): - self.location('/en/cgi-bin/webscr?cmd=_account&nav=0.0') + if self.website == "old": + if not self.is_on_page(AccountPage): + self.location('/en/cgi-bin/webscr?cmd=_account&nav=0.0') elif not self.is_on_page(NewAccountPage): self.location('/businessexp/money') return self.page.get_accounts() def get_account(self, _id): - if self.website == "old" and not not self.is_on_page(AccountPage): - self.location('/en/cgi-bin/webscr?cmd=_account&nav=0.0') + if self.website == "old": + if not self.is_on_page(AccountPage): + self.location('/en/cgi-bin/webscr?cmd=_account&nav=0.0') elif not self.is_on_page(NewAccountPage): self.location('/businessexp/money')