nanliu/puppet-staging — pull request #11 by adrienthebo (2013-06-01 22:55:29+00:00)
Title: [staging_parse] Raise error if given invalid source

A string like 'foo:bar' is a valid URI but contains no path.
URI.parse('foo:bar') returns nil, and calling File.extname(nil) raises
"can't convert nil into String".

This commit ensures that the given URI has a valid path and fails early
if the input is malformed.