Sha256: d87deeec59584aca122277219008fc534c9bcd6c37343c944fbad60768a2ecc0

Contents?: true

Size: 812 Bytes

Versions: 16

Compression:

Stored size: 812 Bytes

Contents

# frozen_string_literal: true

module Lcms
  module Engine
    class RegistrationsController < Devise::RegistrationsController
      # NOTE: remove with reverting confiramble on, need this not to sign in user after sign up
      def create
        build_resource(sign_up_params)

        resource.save
        yield resource if block_given?
        if resource.persisted?
          set_flash_message :notice, :signed_up
          expire_data_after_sign_in!
          respond_with resource, location: after_inactive_sign_up_path_for(resource)
        else
          clean_up_passwords resource
          set_minimum_password_length
          respond_with resource
        end
      end

      private

      def after_inactive_sign_up_path_for(_resource)
        new_user_session_path
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
lcms-engine-0.5.5 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.5.4 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.5.3 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.5.2 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.5.1 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.5.0 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.4.2 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.4.1 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.4.0 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.3.1 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.1.4 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.3.0 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.1.3 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.2.0 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.1.2 app/controllers/lcms/engine/registrations_controller.rb
lcms-engine-0.1.0 app/controllers/lcms/engine/registrations_controller.rb