Sha256: 9f5f1dd7de93534a5758b9e1eb61984822d8c93ca4b4fcf5c4337af5e5324e14
Contents?: true
Size: 429 Bytes
Versions: 2
Compression:
Stored size: 429 Bytes
Contents
module Agilibox::BackUrlConcern extend ActiveSupport::Concern private def default_back_url end def back_url url = [ params[:back_url], request.referer, default_back_url, main_app.try(:root_path), "/", ].select(&:present?).first uri = URI.parse(url) uri.host = nil uri.port = nil uri.scheme = nil uri.user = nil uri.password = nil uri.to_s end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
agilibox-1.9.1 | app/controllers/concerns/agilibox/back_url_concern.rb |
agilibox-1.9.0 | app/controllers/concerns/agilibox/back_url_concern.rb |