Skip to content

Commit

Permalink
Fix capitalization of role (#902)
Browse files Browse the repository at this point in the history
* Fix capitalization of role

* Fix test
  • Loading branch information
wilco375 authored Jan 5, 2024
1 parent 7b1df95 commit d3b686f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/models/role.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ class Role < ApplicationRecord

def name
if treasurer?
Rails.application.config.x.treasurer_title
Rails.application.config.x.treasurer_title.capitalize
elsif main_bartender?
'Hoofdtapper'
end
Expand Down
2 changes: 1 addition & 1 deletion spec/models/role_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
context 'when treasurer' do
subject(:role) { build_stubbed(:role, role_type: :treasurer) }

it { expect(role.name).to eq Rails.application.config.x.treasurer_title }
it { expect(role.name).to eq Rails.application.config.x.treasurer_title.capitalize }
end

context 'when main bartender' do
Expand Down

0 comments on commit d3b686f

Please sign in to comment.