Skip to content

Commit f35976b

Browse files
committed
Ensure only js classes are shown
1 parent 2ccfb7a commit f35976b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

scripts/api.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,9 @@
3737
return value[0].toLowerCase() + value.slice(1);
3838
});
3939

40-
resp.forEach(function(ctor) {
40+
resp.filter(function(ctor) {
41+
return ctor.jsClassName;
42+
}).forEach(function(ctor) {
4143
// Add nav entry.
4244
var anchor = $("<a href='#" + ctor.jsClassName + "'><li>" + ctor.jsClassName + "</li><ul class='subnav'></ul></a>").appendTo(scrollable);
4345

@@ -46,7 +48,7 @@
4648

4749
content.append(contentOutput);
4850

49-
ctor.functions.forEach(function(func) {
51+
(ctor.functions||[]).forEach(function(func) {
5052
var isPrototype = func.isPrototypeMethod ? "#" : ".";
5153
anchor.find(".subnav").append("<a href='#" + ctor.jsClassName + "/function/" + func.jsFunctionName + "'><li>" + ctor.jsClassName + isPrototype + func.jsFunctionName + "</li></a>");
5254
});

0 commit comments

Comments
 (0)