{"action":"opened","issue":{"url":"https://api.github.com/repos/nolimits4web/Swiper/issues/1944","repository_url":"https://api.github.com/repos/nolimits4web/Swiper","labels_url":"https://api.github.com/repos/nolimits4web/Swiper/issues/1944/labels{/name}","comments_url":"https://api.github.com/repos/nolimits4web/Swiper/issues/1944/comments","events_url":"https://api.github.com/repos/nolimits4web/Swiper/issues/1944/events","html_url":"https://github.com/nolimits4web/Swiper/issues/1944","id":192265407,"number":1944,"title":"Uncaught ReferenceError: i is not defined","user":{"login":"crisanlucid","id":340843,"avatar_url":"https://avatars.githubusercontent.com/u/340843?v=3","gravatar_id":"","url":"https://api.github.com/users/crisanlucid","html_url":"https://github.com/crisanlucid","followers_url":"https://api.github.com/users/crisanlucid/followers","following_url":"https://api.github.com/users/crisanlucid/following{/other_user}","gists_url":"https://api.github.com/users/crisanlucid/gists{/gist_id}","starred_url":"https://api.github.com/users/crisanlucid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/crisanlucid/subscriptions","organizations_url":"https://api.github.com/users/crisanlucid/orgs","repos_url":"https://api.github.com/users/crisanlucid/repos","events_url":"https://api.github.com/users/crisanlucid/events{/privacy}","received_events_url":"https://api.github.com/users/crisanlucid/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-11-29T12:11:30Z","updated_at":"2016-11-29T12:11:30Z","closed_at":null,"body":"This is a (multiple allowed):\r\n* [x] bug\r\n\r\n* Swiper Version: v3.4.0\r\n* Platform/Target and Browser Versions: Chrome on Linux\r\n\r\n### What you did\r\nfile: swiper.jquery.js\r\n\r\nset Swiper with attribute  {\"autoheight\": true}\r\n\r\n### Actual Behavior\r\n_Uncaught ReferenceError: i is not defined_\r\n\r\n```javascript\r\nb.updateautoheight = function() {\r\n    var e = []\r\n        , a = 0;\r\n    if (\"auto\" !== b.params.slidesperview && b.params.slidesperview > 1)\r\n        for (i = 0; i < math.ceil(b.params.slidesperview); i++) {\r\n            var t = b.activeindex + i;\r\n            if (t > b.slides.length)\r\n                break;\r\n            e.push(b.slides.eq(t)[0])\r\n        }\r\n    else\r\n        e.push(b.slides.eq(b.activeindex)[0]);\r\n    for (i = 0; i < e.length; i++)\r\n        if (\"undefined\" != typeof e[i]) {\r\n            var s = e[i].offsetheight;\r\n            a = s > a ? s : a\r\n        }\r\n    a && b.wrapper.css(\"height\", a + \"px\")\r\n}\r\n\r\n```\r\n\r\nI suggest to declare parameter i at beginning of function above ||  declare fore each loop \r\n\r\n```javascript\r\nvar e = []\r\n    , a = 0,\r\n      i = 0;\r\n```\r\n\r\n"}}
{"actor":{"display_login":"crisanlucid"}}