posthog-ruby 3.26.0 → 3.26.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e122582ed410310c48c95e3bffbac3b3255a055ec0e527769421162b672b4b85
4
- data.tar.gz: 4491c33e03c11dbc78c4f6e71f378ef28f4a17558e12ce48df1008d63a417fa3
3
+ metadata.gz: 669accebe3e1d0205f2d74494765a7ac02aafc58ba2dc33f253628d8d0adfce0
4
+ data.tar.gz: 1a38ec678c23fc04922030b9c546374990d36d18c7e4c0a065b1bbf4b9d57748
5
5
  SHA512:
6
- metadata.gz: 70c0f2c24d1528b88ccb6d79302b285b2ba01759d4cd87c5009e3d7a46ac518b79a3a365a68a92176d6b69c7ea6b129c35c6c9c0d92a71c0815d41e96a8d121c
7
- data.tar.gz: 45c8a888745f5e873084ea828e65e2982b73391ce9ac901473f9390f600e912600754dd67553734ace2e1aa330ad1935c98ebeee3d80f989b5f4c27e45614f94
6
+ metadata.gz: aea72b91211ee5539434b7a6e3131d75f93ae452c2b67c306ab90f13f6a1e009c0b07c7502391dc702632b177ce435b1f06a620909af8ff47bb33a32014e0eec
7
+ data.tar.gz: 2fe6f690c5dbc039543c40b1a8c79e550c0c4c10fffc8bf96a69e5a2ff268a3fd6f2f76b029625c5b742452b480e9cde92d7af88ef7f38984b64fc5bebe031ae
@@ -187,7 +187,8 @@ module PostHog
187
187
 
188
188
  # Warn when multiple clients are created with the same API key (can cause dropped events)
189
189
  unless @disabled || opts[:test_mode] || opts[:disable_singleton_warning]
190
- previous_count = self.class._increment_instance_count(@api_key)
190
+ previous_count = PostHog::Client._increment_instance_count(@api_key)
191
+ @instance_registered = true
191
192
  if previous_count >= 1
192
193
  logger.warn(
193
194
  'Multiple PostHog client instances detected for the same API key. ' \
@@ -947,7 +948,7 @@ module PostHog
947
948
 
948
949
  flushed = false
949
950
  begin
950
- self.class._decrement_instance_count(@api_key) unless @disabled
951
+ PostHog::Client._decrement_instance_count(@api_key) if @instance_registered
951
952
  @feature_flags_poller&.shutdown_poller
952
953
  flushed =
953
954
  if @sync_mode
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module PostHog
4
- VERSION = '3.26.0'
4
+ VERSION = '3.26.1'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: posthog-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.26.0
4
+ version: 3.26.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - ''