Skip to content
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion app/services/proofing/ddp_result.rb
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def to_h
end

def device_fingerprint
response_body&.dig(:fuzzy_device_id)
response_body&.dig('fuzzy_device_id')
end

private
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@
"tmx_risk_rating": "neutral",
"fraudpoint.score": "500",
"first_name": "WARNING! YOU SHOULD NEVER SEE THIS PII FIELD IN THE LOGS",
"tmx_summary_reason_code": ["Identity_Negative_History"],
"tmx_summary_reason_code": [
"Identity_Negative_History"
],
"session_id": "super-cool-test-session-id",
"account_lex_id": "super-cool-test-lex-id"
}
"account_lex_id": "super-cool-test-lex-id",
"fuzzy_device_id": "WARNING! YOU SHOULD NEVER SEE THIS PII FIELD IN THE LOGS"
}
4 changes: 2 additions & 2 deletions spec/services/proofing/ddp_result_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@
describe '#to_h' do
context 'when response_body is present' do
it 'is redacted' do
response_body = { first_name: 'Jonny Proofs' }
response_body = { 'first_name' => 'Jonny Proofs' }
result = Proofing::DdpResult.new(response_body:)

expect(result.to_h[:response_body]).to eq({})
Expand All @@ -145,7 +145,7 @@
end

describe '#device_fingerprint' do
let(:response_body) { { fuzzy_device_id: '12345' } }
let(:response_body) { { 'fuzzy_device_id' => '12345' } }
subject { described_class.new(response_body:) }

context 'when response_body is present' do
Expand Down