{"action":"created","issue":{"url":"https://api.github.com/repos/DataTables/DataTables/issues/678","labels_url":"https://api.github.com/repos/DataTables/DataTables/issues/678/labels{/name}","comments_url":"https://api.github.com/repos/DataTables/DataTables/issues/678/comments","events_url":"https://api.github.com/repos/DataTables/DataTables/issues/678/events","html_url":"https://github.com/DataTables/DataTables/issues/678","id":108132335,"number":678,"title":"bug(sort): throw \"TypeError: Cannot read property 'aDataSort' of undefined\" if no column ","user":{"login":"douglasduteil","id":730511,"avatar_url":"https://avatars.githubusercontent.com/u/730511?v=3","gravatar_id":"","url":"https://api.github.com/users/douglasduteil","html_url":"https://github.com/douglasduteil","followers_url":"https://api.github.com/users/douglasduteil/followers","following_url":"https://api.github.com/users/douglasduteil/following{/other_user}","gists_url":"https://api.github.com/users/douglasduteil/gists{/gist_id}","starred_url":"https://api.github.com/users/douglasduteil/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/douglasduteil/subscriptions","organizations_url":"https://api.github.com/users/douglasduteil/orgs","repos_url":"https://api.github.com/users/douglasduteil/repos","events_url":"https://api.github.com/users/douglasduteil/events{/privacy}","received_events_url":"https://api.github.com/users/douglasduteil/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-09-24T13:41:26Z","updated_at":"2015-09-24T15:27:30Z","closed_at":"2015-09-24T15:27:30Z","body":"Hi\r\n\r\nSimply executing the dataTable function with no options on an empty table throws the error below\r\n\r\n```js\r\n $('#myTable').DataTable();\r\n// Uncaught TypeError: Cannot read property 'aDataSort' of undefined\r\n```\r\n\r\nAt https://github.com/DataTables/DataTables/blob/1.10.9/media/js/jquery.dataTables.js#L4524\r\nDemo : http://live.datatables.net/cocikoyo/1/edit (open the console)\r\n\r\nSeems like the sort configuration try to access to the columns without testing if there are any."},"comment":{"url":"https://api.github.com/repos/DataTables/DataTables/issues/comments/142963065","html_url":"https://github.com/DataTables/DataTables/issues/678#issuecomment-142963065","issue_url":"https://api.github.com/repos/DataTables/DataTables/issues/678","id":142963065,"user":{"login":"douglasduteil","id":730511,"avatar_url":"https://avatars.githubusercontent.com/u/730511?v=3","gravatar_id":"","url":"https://api.github.com/users/douglasduteil","html_url":"https://github.com/douglasduteil","followers_url":"https://api.github.com/users/douglasduteil/followers","following_url":"https://api.github.com/users/douglasduteil/following{/other_user}","gists_url":"https://api.github.com/users/douglasduteil/gists{/gist_id}","starred_url":"https://api.github.com/users/douglasduteil/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/douglasduteil/subscriptions","organizations_url":"https://api.github.com/users/douglasduteil/orgs","repos_url":"https://api.github.com/users/douglasduteil/repos","events_url":"https://api.github.com/users/douglasduteil/events{/privacy}","received_events_url":"https://api.github.com/users/douglasduteil/received_events","type":"User","site_admin":false},"created_at":"2015-09-24T15:27:30Z","updated_at":"2015-09-24T15:27:30Z","body":"Hum yeah. I'm actually codding a work around to do the dynamically columns number thing. So I guess I will just detect that  these is no columns in my code and add a fake one.\r\nThanks\r\n"}}