re-add changes to find apple attachments, with old typos fixed
re-remove old way of handling attachments; use longest function instead of builtin max function
initialize attachments var; use a working longest function
remove 'longest' import
Merge pull request #4 from bepetersn/FIXED-finding-apple-attachments

re-add changes to find apple attachments, with old typos fixed