lib/rabbit/command/rabbit.rb in rabbit-2.1.3 vs lib/rabbit/command/rabbit.rb in rabbit-2.1.4
- old
+ new
@@ -665,10 +665,11 @@
if rest_arguments.empty?
file_name = choose_source_file_by_dialog
exit if file_name.nil?
rest_arguments = [file_name]
@options.source_type = Source::File
- elsif rest_arguments.size == 1 and /\Ahttps?:\/\// =~ rest_arguments[0]
+ elsif rest_arguments.size == 1 and
+ /\A(?:https?|file):\/\//i =~ rest_arguments[0]
@options.source_type = Source::URI
else
@options.source_type = Source::File
end
end