Skip to content

Commit

Permalink
fix regex to identify each instance
Browse files Browse the repository at this point in the history
  • Loading branch information
pzupan committed Feb 11, 2019
1 parent c50171c commit b059f60
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 190 deletions.
186 changes: 0 additions & 186 deletions active_storage:install

This file was deleted.

6 changes: 2 additions & 4 deletions app/helpers/extension_versions_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,8 @@ def render_document(content, extension, repo_loc = "", version = "", hard_wrap:
content
end
end
# exlude any domains which we can call directly
unless document[/(?:travis-ci)/]
document.gsub!(/src="(?!http)(.+)"/, %(src="https://github.com/#{repo_loc}/raw/#{version}/\\1"))
end
# exlude (?!.*) any domains which we should call directly
document.gsub!(/src="(?!.*travis.ci)(?!http)(.+)"/, %(src="https://github.com/#{repo_loc}/raw/#{version}/\\1"))
document.html_safe
end

Expand Down
Binary file removed b08124dc-1276-4f25-b6bf-6bb83442c6cc
Binary file not shown.

0 comments on commit b059f60

Please sign in to comment.