aboutsummaryrefslogtreecommitdiffstats
path: root/packages/website/ts
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2017-11-29 22:48:11 +0800
committerFabio Berger <me@fabioberger.com>2017-11-29 22:48:11 +0800
commit0e856ccfab98fc2f9c105efca91b09adef6c3da0 (patch)
tree2d5001b04fbc94e1691b12a3c647265596b37b7b /packages/website/ts
parent6093ee78241c42b66be95bf8bfff28d48bf41d45 (diff)
downloaddexon-sol-tools-0e856ccfab98fc2f9c105efca91b09adef6c3da0.tar
dexon-sol-tools-0e856ccfab98fc2f9c105efca91b09adef6c3da0.tar.gz
dexon-sol-tools-0e856ccfab98fc2f9c105efca91b09adef6c3da0.tar.bz2
dexon-sol-tools-0e856ccfab98fc2f9c105efca91b09adef6c3da0.tar.lz
dexon-sol-tools-0e856ccfab98fc2f9c105efca91b09adef6c3da0.tar.xz
dexon-sol-tools-0e856ccfab98fc2f9c105efca91b09adef6c3da0.tar.zst
dexon-sol-tools-0e856ccfab98fc2f9c105efca91b09adef6c3da0.zip
Fix phantom `Contracts` section issue
Diffstat (limited to 'packages/website/ts')
-rw-r--r--packages/website/ts/pages/documentation/docs_info.ts5
1 files changed, 5 insertions, 0 deletions
diff --git a/packages/website/ts/pages/documentation/docs_info.ts b/packages/website/ts/pages/documentation/docs_info.ts
index fd8e9df74..7fe5d9b31 100644
--- a/packages/website/ts/pages/documentation/docs_info.ts
+++ b/packages/website/ts/pages/documentation/docs_info.ts
@@ -47,6 +47,11 @@ export class DocsInfo {
}
const finalMenu = _.cloneDeep(this.docsInfo.menu);
+ if (_.isUndefined(finalMenu.contracts)) {
+ return finalMenu;
+ }
+
+ // TODO: refactor to include more sections then simply the `contracts` section
finalMenu.contracts = _.filter(finalMenu.contracts, (contractName: string) => {
const versionIntroducedIfExists = this.docsInfo.menuSubsectionToVersionWhenIntroduced[contractName];
if (!_.isUndefined(versionIntroducedIfExists)) {