Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Fixes #62, normalize endpoint URI

* Performs basic URI validation (no spaces, special characters, etc.)
* Normalizes default port numbers (removes 80, 443 from http(s) links)
  • Loading branch information...
commit 44547f70e4de31f25d851ef0a623eeed893b9b27 1 parent 263df78
Boris Parak authored March 01, 2013

Showing 1 changed file with 1 addition and 4 deletions. Show diff stats Hide diff stats

  1. 5  lib/occi/bin/occi_opts.rb
5  lib/occi/bin/occi_opts.rb
@@ -82,10 +82,7 @@ def self.parse(args, test_env = false)
82 82
                   "--endpoint URI",
83 83
                   String,
84 84
                   "OCCI server URI, defaults to '#{options.endpoint}'") do |endpoint|
85  
-            # Do some basic validation of the endpoint URI
86  
-            URI(endpoint)
87  
-
88  
-            options.endpoint = endpoint
  85
+            options.endpoint = URI(endpoint).to_s
89 86
           end
90 87
 
91 88
           opts.on("-n",

0 notes on commit 44547f7

Please sign in to comment.
Something went wrong with that request. Please try again.