Commit 29fc7b7a5d013b12f55fc0e27645155dd54f0642
1 parent
ed82bd64
Exists in
master
and in
1 other branch
Fixed normalize_backtrace method in errbit:db:regenerate_fingerprints task
Showing
1 changed file
with
4 additions
and
4 deletions
Show diff stats
lib/tasks/errbit/database.rake
... | ... | @@ -2,13 +2,13 @@ require 'digest/sha1' |
2 | 2 | |
3 | 3 | namespace :errbit do |
4 | 4 | namespace :db do |
5 | - | |
5 | + | |
6 | 6 | desc "Updates cached attributes on Problem" |
7 | 7 | task :update_problem_attrs => :environment do |
8 | 8 | puts "Updating problems" |
9 | 9 | Problem.all.each(&:cache_notice_attributes) |
10 | 10 | end |
11 | - | |
11 | + | |
12 | 12 | desc "Updates Problem#notices_count" |
13 | 13 | task :update_notices_count => :environment do |
14 | 14 | puts "Updating problem.notices_count" |
... | ... | @@ -16,7 +16,7 @@ namespace :errbit do |
16 | 16 | p.update_attributes(:notices_count => p.notices.count) |
17 | 17 | end |
18 | 18 | end |
19 | - | |
19 | + | |
20 | 20 | desc "Delete resolved errors from the database. (Useful for limited heroku databases)" |
21 | 21 | task :clear_resolved => :environment do |
22 | 22 | count = Problem.resolved.count |
... | ... | @@ -29,7 +29,7 @@ namespace :errbit do |
29 | 29 | |
30 | 30 | def normalize_backtrace(backtrace) |
31 | 31 | backtrace[0...3].map do |trace| |
32 | - trace.merge 'method' => trace['method'].gsub(/[0-9_]{10,}+/, "__FRAGMENT__") | |
32 | + trace.merge 'method' => trace['method'].to_s.gsub(/[0-9_]{10,}+/, "__FRAGMENT__") | |
33 | 33 | end |
34 | 34 | end |
35 | 35 | ... | ... |