diff options
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/admin/accounts_controller.rb | 13 | ||||
-rw-r--r-- | app/controllers/application_controller.rb | 2 |
2 files changed, 14 insertions, 1 deletions
diff --git a/app/controllers/admin/accounts_controller.rb b/app/controllers/admin/accounts_controller.rb new file mode 100644 index 000000000..e84799040 --- /dev/null +++ b/app/controllers/admin/accounts_controller.rb @@ -0,0 +1,13 @@ +# frozen_string_literal: true + +class Admin::AccountsController < ApplicationController + before_action :require_admin! + + layout 'public' + + def index + end + + def show + end +end diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index bb52646a7..5243bc446 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -37,7 +37,7 @@ class ApplicationController < ActionController::Base end def set_user_activity - current_user.touch(:current_sign_in_at) if !current_user.nil? && current_user.current_sign_in_at < 24.hours.ago + current_user.touch(:current_sign_in_at) if !current_user.nil? && (current_user.current_sign_in_at.nil? || current_user.current_sign_in_at < 24.hours.ago) end protected |