Skip to content

Commit

Permalink
Don't store sig images
Browse files Browse the repository at this point in the history
  • Loading branch information
parterburn committed Dec 19, 2023
1 parent ca1626f commit 8990b15
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/lib/email_processor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ def process

# skip signature images
next if @user.id == 293 && attachment&.original_filename == "cropped-IMG-0719-300x86.jpeg"
next if @user.id == 10836 && attachment&.original_filename == "B_Logo.png"
next if @user.id == 2541 && attachment&.original_filename == "image001.jpg"

if (attachment.content_type == "application/octet-stream" || attachment.content_type =~ /^image\/(png|jpe?g|webp|gif|heic|heif)$/i || attachment.original_filename =~ /^(.+\.(heic|heif))$/i) && file_size > 20000
valid_attachments << attachment
Expand Down

0 comments on commit 8990b15

Please sign in to comment.