Fixes #1429
Unified · Split
| @@ -13,8 +13,9 @@ module Docs · 12 unmodified lines | |||
| 13 | # The id of the container `div.section` indicates the page type. | 13 | # The id of the container `div.section` indicates the page type. |
| 14 | # If the id starts with `module-`, then it's an API reference, | 14 | # If the id starts with `module-`, then it's an API reference, |
| 15 | # otherwise it is a note or design doc. | 15 | # otherwise it is a note or design doc. |
| 16 | if at_css('.section')['id'].starts_with? 'module-' | 16 | section_id = at_css('.section')['id'] |
| 17 | /\Amodule-(.*)/.match(article_id)[1] | 17 | if section_id.starts_with? 'module-' |
| 18 | section_id.remove('module-') | ||
| 18 | else | 19 | else |
| 19 | name = get_breadcrumbs()[1] | 20 | name = get_breadcrumbs()[1] |
| 20 | NAME_REPLACEMENTS.fetch(name, name) | 21 | NAME_REPLACEMENTS.fetch(name, name) |