From 16c1d14808330f23bcfa7f186124533c13b44ddc Mon Sep 17 00:00:00 2001 From: Patrick Maia and Victor Shyba Date: Wed, 26 Nov 2014 11:01:22 -0300 Subject: no need to catch if we will just raise --- service/pixelated/bitmask_libraries/session.py | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'service') diff --git a/service/pixelated/bitmask_libraries/session.py b/service/pixelated/bitmask_libraries/session.py index 6b3b5732..1143eb52 100644 --- a/service/pixelated/bitmask_libraries/session.py +++ b/service/pixelated/bitmask_libraries/session.py @@ -35,16 +35,13 @@ SESSIONS = {} def open(username, password, server_name): - try: - certs_home = os.path.abspath(os.path.join(os.path.abspath(__file__), "..", "..", "certificates")) + certs_home = os.path.abspath(os.path.join(os.path.abspath(__file__), "..", "..", "certificates")) - config = LeapConfig(certs_home=certs_home) - provider = LeapProvider(server_name, config) - session = LeapSessionFactory(provider).create(LeapCredentials(username, password)) + config = LeapConfig(certs_home=certs_home) + provider = LeapProvider(server_name, config) + session = LeapSessionFactory(provider).create(LeapCredentials(username, password)) - return session - except: - raise + return session class LeapSession(object): -- cgit v1.2.3