Sha256: c4b114ae58677c566c8eab1eeccab3d9754a7563d60f07baaf89ffeb88a11b73
Contents?: true
Size: 407 Bytes
Versions: 13
Compression:
Stored size: 407 Bytes
Contents
module Wbase class ApplicationController < ActionController::Base include AuthHelper protect_from_forgery with: :exception around_action :tag_logs_with_user_id def tag_logs_with_user_id tag = "user-anonymous" if logged_in? tag = "user-#{ current_user.id } #{ current_user.email }" end Rails.logger.tagged(tag) do yield end end end end
Version data entries
13 entries across 13 versions & 1 rubygems