garrensmith commented on a change in pull request #971: WIP - Refactor
documents/mango addon to use Redux
URL: https://github.com/apache/couchdb-fauxton/pull/971#discussion_r136068827
##########
File path: app/addons/documents/index-results/helpers/shared-helpers.js
##########
@@ -76,10 +76,33 @@ const getDefaultPerPage = () => {
return FauxtonAPI.constants.MISC.DEFAULT_PAGE_SIZE;
};
+const isGhostDoc = (doc) => {
+ // ghost docs are empty results where all properties were
+ // filtered away by mango
+ return !doc || !doc.attributes || !Object.keys(doc.attributes).length;
+};
+
+const getDocId = (doc, docType = 'view') => {
Review comment:
Nice idea here
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services