Compare commits
1 commit
master
...
feature/do
Author | SHA1 | Date | |
---|---|---|---|
|
7efa5e9dd9 |
2 changed files with 3 additions and 1 deletions
|
@ -18,6 +18,7 @@ require 'middleman-core/sitemap/resource'
|
|||
require 'hashie'
|
||||
|
||||
# For URI templating
|
||||
require 'public_suffix'
|
||||
require 'addressable/uri'
|
||||
require 'addressable/template'
|
||||
require 'active_support/inflector'
|
||||
|
@ -357,7 +358,7 @@ module Middleman
|
|||
begin
|
||||
uri = ::Addressable::URI.parse(asset_path)
|
||||
|
||||
if uri.relative? && uri.host.nil? && !asset_path.match(/^[^\/].*[a-z]+\.[a-z]+\/.*/) && (result = yield(asset_path))
|
||||
if uri.relative? && uri.host.nil? && !::PublicSuffix.valid?(asset_path) && (result = yield(asset_path))
|
||||
"#{opening_character}#{result}"
|
||||
else
|
||||
match
|
||||
|
|
|
@ -24,6 +24,7 @@ Gem::Specification.new do |s|
|
|||
s.add_dependency('tilt', ['~> 1.4.1'])
|
||||
s.add_dependency('erubis')
|
||||
s.add_dependency('fast_blank')
|
||||
s.add_dependency('public_suffix')
|
||||
|
||||
# Helpers
|
||||
s.add_dependency('activesupport', ['~> 4.2'])
|
||||
|
|
Loading…
Reference in a new issue