{"action":"closed","issue":{"url":"https://api.github.com/repos/jstedfast/MimeKit/issues/202","labels_url":"https://api.github.com/repos/jstedfast/MimeKit/issues/202/labels{/name}","comments_url":"https://api.github.com/repos/jstedfast/MimeKit/issues/202/comments","events_url":"https://api.github.com/repos/jstedfast/MimeKit/issues/202/events","html_url":"https://github.com/jstedfast/MimeKit/issues/202","id":121303153,"number":202,"title":"Question; Shouldn't MimePart.IsAttachment return true also for linked resources ...?","user":{"login":"polterguy","id":8466933,"avatar_url":"https://avatars.githubusercontent.com/u/8466933?v=3","gravatar_id":"","url":"https://api.github.com/users/polterguy","html_url":"https://github.com/polterguy","followers_url":"https://api.github.com/users/polterguy/followers","following_url":"https://api.github.com/users/polterguy/following{/other_user}","gists_url":"https://api.github.com/users/polterguy/gists{/gist_id}","starred_url":"https://api.github.com/users/polterguy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/polterguy/subscriptions","organizations_url":"https://api.github.com/users/polterguy/orgs","repos_url":"https://api.github.com/users/polterguy/repos","events_url":"https://api.github.com/users/polterguy/events{/privacy}","received_events_url":"https://api.github.com/users/polterguy/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-12-09T17:55:33Z","updated_at":"2015-12-09T19:27:04Z","closed_at":"2015-12-09T19:27:04Z","body":"Howdy, I am creating this message through BodyBuilder with an inline attachment. Headers for attachment becomes something like this;\r\nContent-Type: image/png; name=marvin-headshot.png\r\nContent-Disposition: inline; filename=marvin-headshot.png\r\nContent-Location: marvin-headshot.png\r\nContent-Transfer-Encoding: base64\r\n\r\nWhen I retrieve this message, I realise I cannot use \"IsAttachment\" from MimePart to figure out if it's an attachment or not ...\r\n\r\nI know that according to \"Content-Location\" header this isn't \"really\" an attachment, however, logically in client code, it needs to be handled as an attachment, which normally/often means storing it to some place on disc I guess ...\r\n\r\nSo basically; How do I figure out the difference between an attachment and text content, when I (obviously) cannot use the MimePart.IsAttachment property ...?\r\n\r\nI guess I could figure out such a thing by looking at Content-Type, and realise it's impossible to handle as anything but an attachment, being \"image/png\" that is. But in theory, one might imagine inline attachments that are of type \"text/whatever\" something ...?\r\n\r\nFor instance, a theoretical use case for such a thing, would be to create an inline attachment for CSS, which would create Content-Type of \"text/css\", meaning MimePart would be TextPart, while also being an inline attachment, for linking into some CSS declaration of some piece of HTML in another MimePart. Or for that matter; JavaScript ...? (With all the security issues that would raise put aside for the sake of the argument)\r\n\r\nBut maybe that's stretching it ...\r\n\r\nAnyway, howto figure out if something is an attachment or not ...?\r\n\r\nShould I just check the MimePart.Filename property to see if something is an attachment or not ...?\r\nWould that be the (logical) correct way of figuring out if something is an attachment ...?"}}