Skip to content

Commit

Permalink
Small tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
mayorova committed Sep 19, 2024
1 parent b979e95 commit 52431d5
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion app/lib/event_store/active_record_event_repository.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ class ActiveRecordEventRepository < RailsEventStoreActiveRecord::EventRepository
def build_event_entity(record)
return nil unless record

data = (record.data || {}).merge(
data = record.data.merge(
event_id: record.event_id,
metadata: record.metadata
)
Expand Down
8 changes: 4 additions & 4 deletions app/lib/three_scale/hash_hacks.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,22 +24,22 @@ def sweep

# Convert all keys to lowercase.
def downcase_keys
transform_keys { |key| key.downcase }
transform_keys(&:downcase)
end

# In place version of +downcase_keys+
def downcase_keys!
transform_keys! {|key| key.downcase}
transform_keys!(&:downcase)
end

# Convert all keys to uppercase.
def upcase_keys
transform_keys { |key| key.upcase }
transform_keys(&:upcase)
end

# In place version of +upcase_keys+
def upcase_keys!
transform_keys! { |key| key.upcase }
transform_keys!(&:upcase)
end
end
end
1 change: 0 additions & 1 deletion app/services/finance/billing_service.rb
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ def with_lock

def report_error(error)
message = "Failed to perform billing job: #{error.message}"
Rails.logger.error(message)
System::ErrorReporting.report_error(error, error_message: message,
error_class: error.class.name)
end
Expand Down
2 changes: 1 addition & 1 deletion test/factories/cms.rb
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,6 @@
factory :cms_builtin_legal_term, :parent => :cms_builtin_partial, :class => CMS::Builtin::LegalTerm do
system_name { 'signup_licence' }
sequence(:title) { |n| "Legal Term ##{n}" }
published { "some text" }
draft { "some text" }
end
end

0 comments on commit 52431d5

Please sign in to comment.