{"action":"closed","issue":{"url":"https://api.github.com/repos/ElemeFE/element/issues/2851","repository_url":"https://api.github.com/repos/ElemeFE/element","labels_url":"https://api.github.com/repos/ElemeFE/element/issues/2851/labels{/name}","comments_url":"https://api.github.com/repos/ElemeFE/element/issues/2851/comments","events_url":"https://api.github.com/repos/ElemeFE/element/issues/2851/events","html_url":"https://github.com/ElemeFE/element/issues/2851","id":207994059,"number":2851,"title":"[bug]在使用了default-openeds参数时，index.js会出现报错","user":{"login":"sowhut","id":9245638,"avatar_url":"https://avatars.githubusercontent.com/u/9245638?v=3","gravatar_id":"","url":"https://api.github.com/users/sowhut","html_url":"https://github.com/sowhut","followers_url":"https://api.github.com/users/sowhut/followers","following_url":"https://api.github.com/users/sowhut/following{/other_user}","gists_url":"https://api.github.com/users/sowhut/gists{/gist_id}","starred_url":"https://api.github.com/users/sowhut/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sowhut/subscriptions","organizations_url":"https://api.github.com/users/sowhut/orgs","repos_url":"https://api.github.com/users/sowhut/repos","events_url":"https://api.github.com/users/sowhut/events{/privacy}","received_events_url":"https://api.github.com/users/sowhut/received_events","type":"User","site_admin":false},"labels":[{"id":447924545,"url":"https://api.github.com/repos/ElemeFE/element/labels/need%20repro","name":"need repro","color":"d93f0b","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2017-02-16T02:22:34Z","updated_at":"2017-02-17T07:03:50Z","closed_at":"2017-02-17T07:03:50Z","body":"原因大概是openMenu和closeMenu里要对this.openedMenus进行数组操作，但是**有时候取到的this.openedMenus不是数组类型而是字符串**\r\n\r\n我暂时的处理方法是在进行push或slice等方法之前判断type，然后转换为数组：\r\nvar n=this.openedMenus;(typeof(n)==='string')&&(this.openedMenus=n.substring(1,n.length-1).split(','));\r\n\r\n但是还是希望能找到为什么类型会出现字符串的原因，从根本上解决该问题。"}}
{"actor":{"display_login":"Leopoldthecoder"}}