summaryrefslogtreecommitdiff
path: root/app/node_modules/okview/index.js
diff options
context:
space:
mode:
authorjulie lala <jules@okfoc.us>2015-04-11 11:42:27 -0400
committerjulie lala <jules@okfoc.us>2015-04-11 11:42:27 -0400
commit65c1c6541f98eb863f9a19533f4bdb4bd9e38514 (patch)
tree84cbe0902cc355b9e1556c346f217d1a4cafd552 /app/node_modules/okview/index.js
parent0b6afc1d5aa8a2f33b1c21e04a10c3eaa43870c1 (diff)
parent2b95bcf414f02551a384ef2020958e90431814dd (diff)
merge
Diffstat (limited to 'app/node_modules/okview/index.js')
-rw-r--r--app/node_modules/okview/index.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/node_modules/okview/index.js b/app/node_modules/okview/index.js
index 6eebe6e..2d1c0a0 100644
--- a/app/node_modules/okview/index.js
+++ b/app/node_modules/okview/index.js
@@ -159,10 +159,10 @@ function fetchTemplateData(meta, queries, id) {
// Inform template of ID in generic field
if (manyResult) {
result = result.map(function(data) {
- return assign({}, data, {id: data[resource.idField]})
+ return assign({}, data, {id: resource.getID(data)})
});
} else {
- result = assign({}, result, {id: result[resource.idField]});
+ result = assign({}, result, {id: resource.getID(result)});
}
// If we have a lot of results for a certain type,
// we pluralize the key and yield an array of results