{"action":"opened","issue":{"url":"https://api.github.com/repos/sendgrid/sendgrid-php/issues/213","repository_url":"https://api.github.com/repos/sendgrid/sendgrid-php","labels_url":"https://api.github.com/repos/sendgrid/sendgrid-php/issues/213/labels{/name}","comments_url":"https://api.github.com/repos/sendgrid/sendgrid-php/issues/213/comments","events_url":"https://api.github.com/repos/sendgrid/sendgrid-php/issues/213/events","html_url":"https://github.com/sendgrid/sendgrid-php/issues/213","id":143072436,"number":213,"title":"Not properly handling line returns: Ignoring single line returns.","user":{"login":"wernight","id":145667,"avatar_url":"https://avatars.githubusercontent.com/u/145667?v=3","gravatar_id":"","url":"https://api.github.com/users/wernight","html_url":"https://github.com/wernight","followers_url":"https://api.github.com/users/wernight/followers","following_url":"https://api.github.com/users/wernight/following{/other_user}","gists_url":"https://api.github.com/users/wernight/gists{/gist_id}","starred_url":"https://api.github.com/users/wernight/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wernight/subscriptions","organizations_url":"https://api.github.com/users/wernight/orgs","repos_url":"https://api.github.com/users/wernight/repos","events_url":"https://api.github.com/users/wernight/events{/privacy}","received_events_url":"https://api.github.com/users/wernight/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-03-23T20:32:51Z","updated_at":"2016-03-23T20:32:51Z","closed_at":null,"body":"```\r\n<?php\r\nrequire('vendor/autoload.php');\r\n\r\n$email = new \\SendGrid\\Email();\r\n$email\r\n    ->addTo('example@example.com')\r\n    ->setFrom('example@example.com')\r\n    ->setSubject('test')\r\n    ->setText(\"1\\n2\\r\\n3\\n\\r4\\r5\");\r\n\r\n$sendgrid = new \\SendGrid('API-KEY');\r\n$sendgrid->send($email);\r\n```\r\n\r\n**Expected** (especially when running on Linux):\r\n```\r\n1\r\n2\r\n3\r\n4\r\n5\r\n```\r\n\r\n**Actual**:\r\n```\r\n1 2 3\r\n4 5\r\n```\r\n\r\nDuplicating a line return works: `1\\n\\n2` gives:\r\n\r\n     1\r\n     2\r\n\r\nIt seems that SendGrid or SendGrid-PHP is ignoring single line breaks (as if it was interpreting as some kind of Markdown). This differs also from other transactional e-mail providers.\r\n\r\nNote: `\\r` (Mac OS before X) isn't very common so handling it seems optional but `\\r\\n` (Windows) and `\\n` (Linux) should really both be supported. I find very odd that neither Windows nor Linux line ending are supported."}}