From 61b27a784987d95ab8807dc0922477d06f137e2f Mon Sep 17 00:00:00 2001 From: Sergey Korolev Date: Mon, 16 Oct 2023 13:59:28 +0700 Subject: [PATCH 1/2] Update rails version --- clickmeetings.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clickmeetings.gemspec b/clickmeetings.gemspec index a0fabf2..2322060 100644 --- a/clickmeetings.gemspec +++ b/clickmeetings.gemspec @@ -28,7 +28,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'simplecov' spec.add_development_dependency 'simplecov-gem-profile' spec.add_development_dependency 'webmock', '~> 2' - spec.add_dependency 'activemodel', '>= 4.1', '< 7' + spec.add_dependency 'activemodel', '>= 4.1', '< 8' spec.add_dependency 'anyway_config', '>= 0.3' spec.add_dependency 'faraday', '>= 1.0', '< 3' spec.add_dependency 'faraday_middleware', '>= 1.0' From b2a7df4fc72e95272550b07acdffd21b7976110e Mon Sep 17 00:00:00 2001 From: Sergey Korolev Date: Sat, 25 Nov 2023 16:41:05 +0700 Subject: [PATCH 2/2] Remove thread --- clickmeetings.gemspec | 2 +- lib/clickmeetings.rb | 4 +--- lib/clickmeetings/storage.rb | 6 ++---- 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/clickmeetings.gemspec b/clickmeetings.gemspec index 2322060..d2e11a8 100644 --- a/clickmeetings.gemspec +++ b/clickmeetings.gemspec @@ -28,7 +28,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'simplecov' spec.add_development_dependency 'simplecov-gem-profile' spec.add_development_dependency 'webmock', '~> 2' - spec.add_dependency 'activemodel', '>= 4.1', '< 8' + spec.add_dependency 'activemodel', '>= 6.1', '< 8' spec.add_dependency 'anyway_config', '>= 0.3' spec.add_dependency 'faraday', '>= 1.0', '< 3' spec.add_dependency 'faraday_middleware', '>= 1.0' diff --git a/lib/clickmeetings.rb b/lib/clickmeetings.rb index 150ad87..cc131c2 100644 --- a/lib/clickmeetings.rb +++ b/lib/clickmeetings.rb @@ -40,9 +40,7 @@ def self.with_client(client) end class ClientRegistry # :nodoc: - extend ActiveSupport::PerThreadRegistry - - attr_accessor :client + thread_mattr_accessor :client end require 'clickmeetings/engine' if defined?(Rails) diff --git a/lib/clickmeetings/storage.rb b/lib/clickmeetings/storage.rb index dd940f0..0f80f33 100644 --- a/lib/clickmeetings/storage.rb +++ b/lib/clickmeetings/storage.rb @@ -1,10 +1,8 @@ -require 'active_support/per_thread_registry' +require "active_support/core_ext/module/attribute_accessors_per_thread" module Clickmeetings class Storage - extend ActiveSupport::PerThreadRegistry - - attr_accessor :cm_current_conference, :cm_current_locale, :cm_open_current_account, + thread_mattr_accessor :cm_current_conference, :cm_current_locale, :cm_open_current_account, :cm_private_current_account end end