Skip to content

Commit

Permalink
feat: account.fetch() includes .profile
Browse files Browse the repository at this point in the history
  • Loading branch information
gr2m committed Jul 25, 2016
1 parent 94998d3 commit 50e1ac3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions lib/fetch.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,10 @@ function fetch (state, path) {
return Promise.reject(error)
}
return internals.fetchProperties({
url: state.url + '/session/account',
url: state.url + '/session/account?include=profile',
sessionId: get(state, 'account.session.id'),
path: path
path: path,
include: 'profile'
})

.then(function (properties) {
Expand Down
2 changes: 1 addition & 1 deletion utils/fetch-properties.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ function fetchProperties (options) {
})

.then(function (response) {
var data = deserialise(response.body)
var data = deserialise(response.body, options)

return getProperties(data, options.path)
})
Expand Down

0 comments on commit 50e1ac3

Please sign in to comment.