Sha256: 3667c76d2cdfd0af6b1bba4931df51249ad698e33c9ca90a092151e33ac737b0
Contents?: true
Size: 539 Bytes
Versions: 21
Compression:
Stored size: 539 Bytes
Contents
# frozen_string_literal: true module Decidim # This controller allows the user to accept the cookie policy. class CookiePolicyController < Decidim::ApplicationController skip_before_action :store_current_location def accept response.set_cookie( Decidim.config.consent_cookie_name, value: "true", path: "/", expires: 1.year.from_now.utc ) respond_to do |format| format.js format.html { redirect_back fallback_location: root_path } end end end end
Version data entries
21 entries across 21 versions & 1 rubygems
Version | Path |
---|---|
decidim-core-0.23.0 | app/controllers/decidim/cookie_policy_controller.rb |