chore(ocp)!: Drop \OCP\Util::linkToPublic

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
This commit is contained in:
Christoph Wurst 2023-06-01 20:32:59 +02:00
parent ff661045ed
commit f04ff2c6d7
No known key found for this signature in database
GPG Key ID: CC42AC2A7F0E56D8

View File

@ -277,21 +277,6 @@ class Util {
);
}
/**
* Creates an absolute url for public use
* @param string $service id
* @return string the url
* @since 4.5.0
* @deprecated 15.0.0 - use OCP\IURLGenerator
*/
public static function linkToPublic($service) {
$urlGenerator = \OC::$server->getURLGenerator();
if ($service === 'files') {
return $urlGenerator->getAbsoluteURL('/s');
}
return $urlGenerator->getAbsoluteURL($urlGenerator->linkTo('', 'public.php').'?service='.$service);
}
/**
* Returns the server host name without an eventual port number
* @return string the server hostname