$extensionPath is initialized to null and then only set when no cached
vcs information was found. Instead set it to the proper value as soon as
we know that $extension['path'] exists. This will fix display of license
file links for most extensions.
Change-Id: I93bfedf3ae0cb7e6f9e077aa1d83906f7a3283b2
if ( isset( $extension['path'] ) ) {
global $IP;
+ $extensionPath = dirname( $extension['path'] );
if ( $this->coreId == '' ) {
wfDebug( 'Looking up core head id' );
$coreHeadSHA1 = self::getGitHeadSha1( $IP );
if ( !$vcsVersion ) {
wfDebug( "Getting VCS info for extension $extensionName" );
- $extensionPath = dirname( $extension['path'] );
$gitInfo = new GitInfo( $extensionPath );
$vcsVersion = $gitInfo->getHeadSHA1();
if ( $vcsVersion !== false ) {