1
0
مراية لـ https://github.com/postalserver/postal.git تم المزامنة 2025-11-30 21:32:30 +00:00

feat: remove strip_received_headers config option

This previously removed all Received headers which were sent to the smtp
server when enabled. This is not something that should be happening.
هذا الالتزام موجود في:
Adam Cooke
2024-02-06 21:01:48 +00:00
الأصل 15f9671b66
التزام ed2e62b94f
2 ملفات معدلة مع 0 إضافات و6 حذوفات

عرض الملف

@@ -393,15 +393,10 @@ module Postal
if @header_key && @headers[@header_key.downcase] && @headers[@header_key.downcase].last
@headers[@header_key.downcase].last << data.to_s
end
# If received headers are configured to be stripped and we're currently receiving one
# skip the append methods at the bottom of this loop.
next if Postal.config.smtp_server.strip_received_headers? && @header_key && @header_key.downcase == "received"
else
@header_key, value = data.split(/:\s*/, 2)
@headers[@header_key.downcase] ||= []
@headers[@header_key.downcase] << value
# As above
next if Postal.config.smtp_server.strip_received_headers? && @header_key && @header_key.downcase == "received"
end
end
@data << data