Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recursively apply replace_all() when running the links preprocessor #564

Merged

Conversation

Michael-F-Bryan
Copy link
Contributor

Fixes an issue raised in #558.

Including a Rust file seems broken - https://rust-lang-nursery.github.io/mdBook/format/rust.html. Looks like it was introduced by #532.

Turns out we forgot to recursively apply replace_all() in #532, instead we just iterated over the chapters in the top level without doing any recursion.

As well as fixing the bug mentioned, I've also made the sections field private so we don't accidentally get these sorts of bugs again.

@Michael-F-Bryan Michael-F-Bryan merged commit c89245b into rust-lang:master Jan 21, 2018
@Michael-F-Bryan Michael-F-Bryan deleted the includes-preprocessor branch January 22, 2018 05:52
Ruin0x11 pushed a commit to Ruin0x11/mdBook that referenced this pull request Aug 30, 2020
…ust-lang#564)

* Looks like we forgot to recursively apply replace_all() in rust-lang#532

* Removed some print statements

* Made sure we ignore the rendered dummy_book
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant