From 0ef1f204aa5c100e3fc9d07f840163e3cd4a5ed2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johan=20Wir=C3=A9n?= Date: Fri, 1 Mar 2013 12:24:11 +0100 Subject: [PATCH] Removed urlparsing of gemsource. Not needed --- gem | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/gem b/gem index 6dc51eee96a..021bd4e7fd2 100644 --- a/gem +++ b/gem @@ -62,7 +62,6 @@ examples: author: Johan Wiren ''' import re -from urlparse import urlparse def getinstalledversions(module, remote=False): cmd = [ module.get_bin_path('gem', True) ] @@ -149,13 +148,7 @@ def main(): if module.params['gemsource'] and module.params['state'] == 'latest': module.fail_json(msg="Cannot maintain state=latest when installing from local source") - if module.params['gemsource']: - url=urlparse(module.params['gemsource']) - if url.scheme in [ '', 'file' ] : - module.params['gemsource'] = url.path - else: - module.fail_json(msg="Installation using url scheme %s is not supported." % url.scheme) - else: + if module.params['gemsource'] is not 'null': module.params['gemsource'] = module.params['name'] changed = False