{"action":"created","issue":{"url":"https://api.github.com/repos/alexandrusavin/nodejs-putiosdk/issues/3","repository_url":"https://api.github.com/repos/alexandrusavin/nodejs-putiosdk","labels_url":"https://api.github.com/repos/alexandrusavin/nodejs-putiosdk/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/alexandrusavin/nodejs-putiosdk/issues/3/comments","events_url":"https://api.github.com/repos/alexandrusavin/nodejs-putiosdk/issues/3/events","html_url":"https://github.com/alexandrusavin/nodejs-putiosdk/issues/3","id":162495403,"number":3,"title":"Something broken as of a few days ago?","user":{"login":"bbluemel","id":482215,"avatar_url":"https://avatars.githubusercontent.com/u/482215?v=3","gravatar_id":"","url":"https://api.github.com/users/bbluemel","html_url":"https://github.com/bbluemel","followers_url":"https://api.github.com/users/bbluemel/followers","following_url":"https://api.github.com/users/bbluemel/following{/other_user}","gists_url":"https://api.github.com/users/bbluemel/gists{/gist_id}","starred_url":"https://api.github.com/users/bbluemel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbluemel/subscriptions","organizations_url":"https://api.github.com/users/bbluemel/orgs","repos_url":"https://api.github.com/users/bbluemel/repos","events_url":"https://api.github.com/users/bbluemel/events{/privacy}","received_events_url":"https://api.github.com/users/bbluemel/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/alexandrusavin/nodejs-putiosdk/labels/bug","name":"bug","color":"fc2929"}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-06-27T16:38:12Z","updated_at":"2016-06-27T20:51:35Z","closed_at":"2016-06-27T20:49:16Z","body":"Hi,\r\n\r\nThis was working perfectly for ages (since my last issue) :) ..\r\n\r\nHowever now it doesn't seem to be working at all, and not giving any indication as to why...\r\n\r\nMy code:\r\n\r\n```\r\nconst Client = require('putiosdk');\r\nputioClient = new Client('XXXXXX');\r\nfs = require('fs');\r\n\r\n\r\nvar recurseFolder = (folderid, downloadFolder) => {\r\n    putioClient.file.list({parent_id: folderid}, (err, result) => {\r\n        if ( result && result.files ) {\r\n            for ( var file in result.files ) {\r\n                var thefile = result.files[file];\r\n                if ( thefile.content_type == 'application/x-directory' ) {\r\n                    recurseFolder(thefile.id, downloadFolder);\r\n                } else {\r\n                    switch (thefile.extension) {\r\n                        case 'mkv':\r\n                        case 'mp4':\r\n                            try {\r\n                                fs.statSync(downloadFolder + thefile.name);\r\n                                console.log( thefile.name + ' exists' );   \r\n                            } catch(ex) {\r\n                                console.log( thefile.name + ' doesn\\'t exist - downloading' );\r\n                                putioClient.file.download({file_id: thefile.id}).pipe(fs.createWriteStream(downloadFolder + thefile.name));\r\n                            }\r\n                        break;\r\n                    }\r\n                }\r\n            }\r\n        } else {\r\n            console.log( err );\r\n            console.log( result );\r\n            console.log( this );\r\n        }\r\n    });\r\n}\r\n```\r\n\r\nThen I just call:\r\n```recurseFolder(0000000, 'I:\\\\put.io\\\\');```\r\n\r\nIn the console I just get:\r\n```\r\nnull\r\n{}\r\n{}\r\n```\r\n\r\nAny ideas? I'm guessing it's down to either a put.io change or possibly a windows update that may have caused it?\r\n\r\nCheers\r\n\r\nBen\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/alexandrusavin/nodejs-putiosdk/issues/comments/228871479","html_url":"https://github.com/alexandrusavin/nodejs-putiosdk/issues/3#issuecomment-228871479","issue_url":"https://api.github.com/repos/alexandrusavin/nodejs-putiosdk/issues/3","id":228871479,"user":{"login":"alexandrusavin","id":1612455,"avatar_url":"https://avatars.githubusercontent.com/u/1612455?v=3","gravatar_id":"","url":"https://api.github.com/users/alexandrusavin","html_url":"https://github.com/alexandrusavin","followers_url":"https://api.github.com/users/alexandrusavin/followers","following_url":"https://api.github.com/users/alexandrusavin/following{/other_user}","gists_url":"https://api.github.com/users/alexandrusavin/gists{/gist_id}","starred_url":"https://api.github.com/users/alexandrusavin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexandrusavin/subscriptions","organizations_url":"https://api.github.com/users/alexandrusavin/orgs","repos_url":"https://api.github.com/users/alexandrusavin/repos","events_url":"https://api.github.com/users/alexandrusavin/events{/privacy}","received_events_url":"https://api.github.com/users/alexandrusavin/received_events","type":"User","site_admin":false},"created_at":"2016-06-27T20:51:35Z","updated_at":"2016-06-27T20:51:35Z","body":"I just published a new version. It seams that I was using the list endpoint wrong (but the api accepted this).\r\n\r\nShould work now."}}
{"actor":{"display_login":"alexandrusavin"}}