Absolute paths are left unchaged #733

This commit is contained in:
Karel Picman 2017-06-02 14:57:53 +02:00
parent df72fb11be
commit 6019a6089a

View File

@ -105,7 +105,8 @@ class DmsfFile < ActiveRecord::Base
if path.blank?
path = 'dmsf'
else
path.strip!
pn = Pathname.new(path)
return pn if pn.absolute?
end
Rails.root.join(path)
end