HomePhabricator

Add file repo at setup time, not on registration

Authored by hashar on Aug 24 2018, 12:47 PM.

Description

Add file repo at setup time, not on registration

Adding a repo to $wgForeignFileRepos relies on the defines BS_DATA_DIR
and BS_DATA_PATH. They are provided by BlueSpiceFoundation however the
extension might not have been loaded yet. For example:

wfLoadExtensions( [
   'BlueSpiceAvatars',
   'BlueSpiceFoundation',
] );

In this case the defines are not set and PHP notices are sent.

Move the configuration to the SetupAfterCache.

Setup.php automatically sets the 'backend', but that is done before the
SetupAfterCache hook. Add a backend named Avatars-backend.

Bug: T202412
Change-Id: Ibcc8f79ec229d36f76d3cdfa61ffd2e60f7d7c34

Details

Committed
hasharAug 24 2018, 1:08 PM
Parents
rEBSYf3f1461061d7: Merge "Refactoring BlueSpiceAvatars"
Branches
Unknown
Tags
Unknown
References
refs/changes/56/455156/2
ChangeId
Ibcc8f79ec229d36f76d3cdfa61ffd2e60f7d7c34