chore(doc-gen): fix error-doc processor

The meta-data should be parsed from the name not the id.
This commit is contained in:
Peter Bacon Darwin
2014-03-07 05:34:13 +00:00
parent 486f1b4e51
commit 02cc2b2014

View File

@@ -22,6 +22,12 @@ module.exports = {
_.forEach(docs, function(doc) {
if ( doc.docType === 'error' ) {
// Parse out the error info from the id
parts = doc.name.split(':');
doc.namespace = parts[0];
doc.name = parts[1];
var namespaceDoc = errorNamespaces[doc.namespace];
if ( !namespaceDoc ) {
// First time we came across this namespace, so create a new one