Page MenuHomePhabricator

BookManager: Optimize function addText to avoid unecessary processing
Closed, ResolvedPublic

Description

The current version of function addText (r84179) creates a default navigation bar with links to previous and next chapters even in cases where they won't be displayed.

The attached patch should reduce the processing of the function, returning earlier if the navigation bars will not be added and avoiding multiple identical tests of some variables ($prev, $next, BookManager). See comments on r83841. Some variables were renamed for clarity.


Version: unspecified
Severity: enhancement

Details

Reference
bz28116