{"issue":{"state":"closed","pull_request":{"diff_url":null,"html_url":null,"patch_url":null},"milestone":null,"user":{"avatar_url":"https://secure.gravatar.com/avatar/c0ffbda2aaf58c66407e55f9091acde8?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"c0ffbda2aaf58c66407e55f9091acde8","url":"https://api.github.com/users/smurthas","login":"smurthas","id":399496},"assignee":null,"updated_at":"2011-11-15T23:21:00Z","labels":[],"closed_at":"2011-11-15T23:21:00Z","comments":1,"url":"https://api.github.com/repos/LockerProject/Locker/issues/435","body":"The fields param on the /Me/links endpoint doesn't quite seem to be working for encounters. For instance, you would expect the following query to return only the encounters array and within that only the from field for each encounter:\r\n\r\nhttp://localhost:8042/Me/links/?limit=10&fields={\"encounters.from\":1}&full=true\r\n\r\nInstead if returns a bunch of empty encounters arrays:\r\n\r\n```\r\n[{\r\n    \"_id\": \"4ec173acd6ffe6fc6da3964a\",\r\n    \"encounters\": []\r\n},\r\n{\r\n    \"_id\": \"4ec17338d6ffe6fc6da39644\",\r\n    \"encounters\": []\r\n},\r\n{\r\n    \"_id\": \"4ec172c3d6ffe6fc6da39640\",\r\n    \"encounters\": []\r\n},\r\n...\r\n```\r\n\r\nAdditionally, a query to\r\n\r\nhttp://localhost:8042/Me/links/?limit=10&fields={\"from\":1, \"link\":1}&full=true\r\n\r\nwill return something closer to the desired result:\r\n\r\n```\r\n[{\r\n    \"_id\": \"4ec173acd6ffe6fc6da3964a\",\r\n    \"link\": \"http://gartner.mediasite.com/mediasite/play/9cfe6bba5c7941e09bee95eb63f769421d?t=1320659595\",\r\n    \"encounters\": [{\r\n        \"_id\": \"4ec173acd6ffe6fc6da3964b\",\r\n        \"from\": \"chris dixon\",\r\n        \"link\": \"http://gartner.mediasite.com/mediasite/play/9cfe6bba5c7941e09bee95eb63f769421d?t=1320659595\"\r\n    },\r\n    {\r\n        \"_id\": \"4ec1749ed6ffe6fc6da39652\",\r\n        \"from\": \"Steve Schlafman\",\r\n        \"link\": \"http://gartner.mediasite.com/mediasite/play/9cfe6bba5c7941e09bee95eb63f769421d?t=1320659595\"\r\n    }]\r\n},\r\n{\r\n    \"_id\": \"4ec17338d6ffe6fc6da39644\",\r\n    \"link\": \"http://blog.vaultpress.com/2011/11/14/announcing-multisite-support/\",\r\n    \"encounters\": [{\r\n        \"_id\": \"4ec17338d6ffe6fc6da39645\",\r\n        \"from\": \"Toni Schneider\",\r\n        \"link\": \"http://blog.vaultpress.com/2011/11/14/announcing-multisite-support/\"\r\n    }]\r\n},\r\n...\r\n```\r\n\r\nHowever, a query to http://localhost:8042/Me/links/?limit=10&fields={\"from\":1}&full=true returns the same a the first result.","html_url":"https://github.com/LockerProject/Locker/issues/435","title":"/Me/links endpoint fields param exhibits strange behavior","number":435,"id":2235473,"created_at":"2011-11-14T20:17:20Z"},"action":"closed"}