{"issue":{"created_at":"2011-12-06T17:19:01Z","state":"closed","updated_at":"2011-12-12T19:06:36Z","comments":4,"user":{"gravatar_id":"e872917c271b2df6242ef18cf107fc93","id":4397,"url":"https://api.github.com/users/anthonywebb","avatar_url":"https://secure.gravatar.com/avatar/e872917c271b2df6242ef18cf107fc93?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","login":"anthonywebb"},"body":"I'm trying to get a simple file to updload but am seeing an issue:\r\n\r\n{ stack: [Getter/Setter],\r\n  arguments: undefined,\r\n  type: undefined,\r\n  message: 'Cannot upload file without `content-length` header' }\r\n\r\nHere is the simple code to post the file:\r\n\r\n    cloud.setAuth(function () {\r\n        cloud.addFile('avatars', { remote: photoname, local: './uploads/temp.jpg' }, function (err, uploaded) {\r\n            if(err){\r\n                console.log(err);\r\n            }\r\n            else {\r\n                console.log(uploaded);\r\n            }\r\n        });\r\n    });\r\n\r\nLikely something small but I cant see to make it work?\r\n\r\nNode is v 4.12","assignee":null,"number":22,"id":2464814,"labels":[],"pull_request":{"patch_url":null,"html_url":null,"diff_url":null},"title":"addFile needs content-length?","html_url":"https://github.com/nodejitsu/node-cloudfiles/issues/22","closed_at":"2011-12-06T17:52:19Z","url":"https://api.github.com/repos/nodejitsu/node-cloudfiles/issues/22","milestone":null},"action":"created","comment":{"created_at":"2011-12-12T19:06:36Z","updated_at":"2011-12-12T19:06:36Z","user":{"gravatar_id":"15f514278e09962521274be4f59f727b","id":145951,"url":"https://api.github.com/users/kainosnoema","avatar_url":"https://secure.gravatar.com/avatar/15f514278e09962521274be4f59f727b?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","login":"kainosnoema"},"body":"I had this same issue, but with a ReadableStream—obviously you can't always know the length of a stream ahead of time. Will this always be a requirement?","id":3110745,"url":"https://api.github.com/repos/nodejitsu/node-cloudfiles/issues/comments/3110745"}}