{"action":"closed","issue":{"url":"https://api.github.com/repos/jshint/jshint/issues/2806","labels_url":"https://api.github.com/repos/jshint/jshint/issues/2806/labels{/name}","comments_url":"https://api.github.com/repos/jshint/jshint/issues/2806/comments","events_url":"https://api.github.com/repos/jshint/jshint/issues/2806/events","html_url":"https://github.com/jshint/jshint/issues/2806","id":122430648,"number":2806,"title":"[BUG?] Syntax error, but I don't think I have one.","user":{"login":"trusktr","id":297678,"avatar_url":"https://avatars.githubusercontent.com/u/297678?v=3","gravatar_id":"","url":"https://api.github.com/users/trusktr","html_url":"https://github.com/trusktr","followers_url":"https://api.github.com/users/trusktr/followers","following_url":"https://api.github.com/users/trusktr/following{/other_user}","gists_url":"https://api.github.com/users/trusktr/gists{/gist_id}","starred_url":"https://api.github.com/users/trusktr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trusktr/subscriptions","organizations_url":"https://api.github.com/users/trusktr/orgs","repos_url":"https://api.github.com/users/trusktr/repos","events_url":"https://api.github.com/users/trusktr/events{/privacy}","received_events_url":"https://api.github.com/users/trusktr/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-12-16T05:16:16Z","updated_at":"2015-12-16T05:41:20Z","closed_at":"2015-12-16T05:41:20Z","body":"I'm on jshint `2.9.1-rc1` and I've got this code:\r\n\r\n```js\r\nimport Spaces from '../../../../modules/collections/Spaces'\r\nimport Orgs from '../../../../modules/collections/Organizations'\r\n\r\n// Redirects to /login if the user isn't logged in.\r\n// reactive\r\nexport function checkLogin(context, redirect, stop) {\r\n    if (!Meteor.userId()) redirect('/login')\r\n}\r\n\r\n// Get the user's last org.\r\n// XXX For now, just gets the user's first org.\r\n// reactive\r\nexport function gotoLastOrg(context, redirect) {\r\n    const user = Meteor.user()\r\n    const orgs = user.organizations().fetch()\r\n\r\n    // for now:\r\n    const lastOrg = orgs[0].slug\r\n\r\n    // TODO\r\n    //if (user.profile.saveLastLocation) {\r\n        //redirect(user.profile.lastLocation)\r\n    //}\r\n\r\n    redirect(\r\n        FlowRouter.path(\r\n            context.route.pathDef,\r\n            {organization: lastOrg}, // params\r\n            {}, // queryParams\r\n        )\r\n    )\r\n}\r\n\r\n// Get the user's last space of the current org.\r\n// XXX For now, just gets the first space.\r\n// reactive\r\nexport function gotoLastSpace(context, redirect) {\r\n    const params = context.params\r\n    const org = context.params.organization\r\n    const spaces = Spaces.find().fetch()\r\n    // redirect( spaces[0] . )\r\n}\r\n```\r\n\r\nwhich results in the following errors, one on each line with the red marks, respectively:\r\n\r\n- `error: Unmatched '{'.`\r\n- `error: Unexpected ')'.`\r\n- `warning: Expected ')' and instead saw '}'.`\r\n- `error: Export declaration must be in global scope.`\r\n\r\n![jshint-errors](https://cloud.githubusercontent.com/assets/297678/11832778/01c9e4cc-a371-11e5-9263-a34cee47baf6.jpg)\r\n"}}