Skip to content

Commit

Permalink
Update plugin.rb
Browse files Browse the repository at this point in the history
  • Loading branch information
angusmcleod committed Oct 4, 2023
1 parent 6472b2a commit e29605c
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions lib/discourse_plugin_statistics/plugin.rb
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,14 @@ def self.discourse_custom_wizard
}

increment_feature_count = lambda do |type, key, value|
if key == 'type' && !subscription_features[type.to_sym][:type][value.to_sym].nil?
subscription_features[type.to_sym][:type][value.to_sym] += 1
elsif !subscription_features[type.to_sym][key.to_sym].nil?
subscription_features[type.to_sym][key.to_sym] += 1
if key == 'type'
if !subscription_features[type.to_sym][:type][value.to_sym].nil?
subscription_features[type.to_sym][:type][value.to_sym] += 1
end
else
if !subscription_features[type.to_sym][key.to_sym].nil?
subscription_features[type.to_sym][key.to_sym] += 1
end
end
end

Expand Down

0 comments on commit e29605c

Please sign in to comment.