bu-navigation
bu-navigation copied to clipboard
Conditionally load core-widget library files
BU Navigation requires the core-widget library files directly, but the other package using that library only requires them if they haven't already been loaded:
https://github.com/bu-ist/bu-learning-blocks/blob/a7d5871370746203d24b15cee3a9de109a7f8b99/bu-learning-blocks.php#L90
This works in the BU context because we load BU Navigation as an MU plugin, so it is always loaded first.
Other installations may not load BU Navigation as an MU plugin, in which case BU Learning Blocks may load first. In this case, BU Navigation may throw errors because the library files were already loaded.
BU Navigation should probably also conditionally load the library files, as BU Learning blocks does.