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

fix: extract x-postal-tag before holding

closes #2684
هذا الالتزام موجود في:
Adam Cooke
2024-02-01 13:53:45 +00:00
الأصل 49cceaa6ca
التزام 6b2bf9062d

عرض الملف

@@ -292,6 +292,12 @@ class UnqueueMessageJob < Postal::Job
next next
end end
# Extract a tag and add it to the message if one doesn't exist
if queued_message.message.tag.nil? && tag = queued_message.message.headers["x-postal-tag"]
log "#{log_prefix} Added tag #{tag.last}"
queued_message.message.update(tag: tag.last)
end
# #
# If the credentials for this message is marked as holding and this isn't manual, hold it # If the credentials for this message is marked as holding and this isn't manual, hold it
# #
@@ -312,12 +318,6 @@ class UnqueueMessageJob < Postal::Job
next next
end end
# Extract a tag and add it to the message if one doesn't exist
if queued_message.message.tag.nil? && tag = queued_message.message.headers["x-postal-tag"]
log "#{log_prefix} Added tag #{tag.last}"
queued_message.message.update(tag: tag.last)
end
# Parse the content of the message as appropriate # Parse the content of the message as appropriate
if queued_message.message.should_parse? if queued_message.message.should_parse?
log "#{log_prefix} Parsing message content as it hasn't been parsed before" log "#{log_prefix} Parsing message content as it hasn't been parsed before"