Skip to content

Commit 51d4e2c

Browse files
committed
chore: rebuild index.php and updater.phar
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
1 parent aac1aae commit 51d4e2c

3 files changed

Lines changed: 21 additions & 3 deletions

File tree

index.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -522,8 +522,6 @@ private function getUpdateServerResponse(): array {
522522
CURLOPT_RETURNTRANSFER => 1,
523523
CURLOPT_URL => $updateURL,
524524
CURLOPT_USERAGENT => 'Nextcloud Updater',
525-
CURLOPT_FOLLOWLOCATION => 1,
526-
CURLOPT_MAXREDIRS => 2,
527525
]);
528526

529527
if ($this->getConfigOption('proxy') !== null) {
@@ -610,6 +608,8 @@ public function downloadUpdate(): void {
610608
CURLOPT_PROGRESSFUNCTION => [$this, 'downloadProgressCallback'],
611609
CURLOPT_FILE => $fp,
612610
CURLOPT_USERAGENT => 'Nextcloud Updater',
611+
CURLOPT_FOLLOWLOCATION => 1,
612+
CURLOPT_MAXREDIRS => 2,
613613
]);
614614

615615
if ($this->getConfigOption('proxy') !== null) {

updater.phar

-76 Bytes
Binary file not shown.

vendor/composer/InstalledVersions.php

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,12 @@
2626
*/
2727
class InstalledVersions
2828
{
29+
/**
30+
* @var string|null if set (by reflection by Composer), this should be set to the path where this class is being copied to
31+
* @internal
32+
*/
33+
private static $selfDir = null;
34+
2935
/**
3036
* @var mixed[]|null
3137
* @psalm-var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}|array{}|null
@@ -322,6 +328,18 @@ public static function reload($data)
322328
self::$installedIsLocalDir = false;
323329
}
324330

331+
/**
332+
* @return string
333+
*/
334+
private static function getSelfDir()
335+
{
336+
if (self::$selfDir === null) {
337+
self::$selfDir = strtr(__DIR__, '\\', '/');
338+
}
339+
340+
return self::$selfDir;
341+
}
342+
325343
/**
326344
* @return array[]
327345
* @psalm-return list<array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
@@ -336,7 +354,7 @@ private static function getInstalled()
336354
$copiedLocalDir = false;
337355

338356
if (self::$canGetVendors) {
339-
$selfDir = strtr(__DIR__, '\\', '/');
357+
$selfDir = self::getSelfDir();
340358
foreach (ClassLoader::getRegisteredLoaders() as $vendorDir => $loader) {
341359
$vendorDir = strtr($vendorDir, '\\', '/');
342360
if (isset(self::$installedByVendor[$vendorDir])) {

0 commit comments

Comments
 (0)