Skip to content

Commit

Permalink
nil protect
Browse files Browse the repository at this point in the history
  • Loading branch information
qinmingyuan committed Oct 26, 2023
1 parent cfac8e4 commit 525a2a6
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ GIT

GIT
remote: https://github.com/work-design/rails_design.git
revision: 05aac51ebab3df772e64860724abd0c28d6b5801
revision: 8347a39a95ad59f0c87446b5360db06d1da4b339
specs:
rails_design (0.0.1)
rails
Expand Down
2 changes: 1 addition & 1 deletion app/models/notice/ext/setting.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module Ext::Setting
end

def unread_count
r = counters.fetch('total', 0)
r = counters&.fetch('total', 0)
r.to_i
end

Expand Down
2 changes: 1 addition & 1 deletion package.gemspec
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Gem::Specification.new do |s|
s.name = 'rails_notice'
s.version = '1.0.3'
s.authors = ['qinmingyuan']
s.authors = ['Mingyuan Qin']
s.email = ['[email protected]']
s.homepage = 'https://github.com/work-design/rails_notice'
s.summary = 'Notification Center for Rails Application'
Expand Down

0 comments on commit 525a2a6

Please sign in to comment.