Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions lib/mini_profiler/storage/redis_store.rb
Original file line number Diff line number Diff line change
Expand Up @@ -233,12 +233,13 @@ def fetch_snapshots_group(group_name)
snapshots = []
corrupt_snapshots = []
redis.hgetall(group_hash_key).each do |id, bytes|
# rubocop:disable Security/MarshalLoad
snapshots << Marshal.load(bytes)
# rubocop:enable Security/MarshalLoad
rescue
corrupt_snapshots << id
end
begin
# rubocop:disable Security/MarshalLoad
snapshots << Marshal.load(bytes)
# rubocop:enable Security/MarshalLoad
rescue
corrupt_snapshots << id
end
if corrupt_snapshots.size > 0
cleanup_corrupt_snapshots(corrupt_snapshots, group_name)
end
Expand Down