{"action":"opened","issue":{"url":"https://api.github.com/repos/enyo/dropzone/issues/1197","labels_url":"https://api.github.com/repos/enyo/dropzone/issues/1197/labels{/name}","comments_url":"https://api.github.com/repos/enyo/dropzone/issues/1197/comments","events_url":"https://api.github.com/repos/enyo/dropzone/issues/1197/events","html_url":"https://github.com/enyo/dropzone/issues/1197","id":128747872,"number":1197,"title":"Event-Bug: passed file - variable isn't filled properly at run-time","user":{"login":"MM-Psiiirus","id":593363,"avatar_url":"https://avatars.githubusercontent.com/u/593363?v=3","gravatar_id":"","url":"https://api.github.com/users/MM-Psiiirus","html_url":"https://github.com/MM-Psiiirus","followers_url":"https://api.github.com/users/MM-Psiiirus/followers","following_url":"https://api.github.com/users/MM-Psiiirus/following{/other_user}","gists_url":"https://api.github.com/users/MM-Psiiirus/gists{/gist_id}","starred_url":"https://api.github.com/users/MM-Psiiirus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MM-Psiiirus/subscriptions","organizations_url":"https://api.github.com/users/MM-Psiiirus/orgs","repos_url":"https://api.github.com/users/MM-Psiiirus/repos","events_url":"https://api.github.com/users/MM-Psiiirus/events{/privacy}","received_events_url":"https://api.github.com/users/MM-Psiiirus/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-01-26T07:39:11Z","updated_at":"2016-01-26T07:39:11Z","closed_at":null,"body":"Hiya,\r\nwhile i was trying to loop through the uploaded files i ran into an massiv problem.\r\n\r\nIf you try to work with the file object passt into the event handler, its just not fully initiated at this time.\r\n\r\nSo my problem is i cant match my file object with my XHR-Response to get some extra data.\r\n\r\nEnclosed an litte example\r\n```\r\n        myDropzone.on(\"success\", function (file, responseText) {\r\nconsole.log(file) // this will look fine...because its just refrences the object with is not 100% load here\r\nconsole.log(file.id) //this will crash because it trys to access an undefined variable\r\n\r\nsetTimeout(function(){console.log(file)},500); // this will work too but is kind of ugly \r\n        });\r\n``` \r\n\r\nCheers Toni\r\n"}}