Commit baaabb06 by liangyuzhe

ap only

parent af3f55fc
......@@ -33,6 +33,8 @@ class PushsController < ApplicationController
user_device_exist = false
ActiveRecord::Base.connected_to(role: db_role) do
user_device_exist = UserDevice.where(user_id: params[:user_id]).exists?
byebug
stale?(last_modified: UserDevice.where(user_id: params[:user_id]).last.updated_at)
end
unless user_device_exist
......
......@@ -9,7 +9,7 @@ Bundler.require(*Rails.groups)
module AppPush
class Application < Rails::Application
# Initialize configuration defaults for originally generated Rails version.
config.load_defaults 5.2
config.load_defaults 6.0
require_relative '../app/services/settings'
# Settings in config/environments/* take precedence over those specified here.
......@@ -34,5 +34,6 @@ module AppPush
config.active_job.queue_adapter = :sidekiq
config.api_only = true
end
end
......@@ -58,5 +58,5 @@ Rails.application.configure do
# Use an evented file watcher to asynchronously detect changes in source code,
# routes, locales, etc. This feature depends on the listen gem.
config.file_watcher = ActiveSupport::EventedFileUpdateChecker
end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment