Skip to content

Commit

Permalink
chore: Remove legacy reference provider
Browse files Browse the repository at this point in the history
Signed-off-by: Julius Härtl <jus@bitgrid.net>
  • Loading branch information
juliusknorr committed Mar 12, 2024
1 parent eb4d746 commit 61472fc
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 85 deletions.
19 changes: 1 addition & 18 deletions lib/AppInfo/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@
use OCA\Tables\Listener\LoadAdditionalListener;
use OCA\Tables\Listener\TablesReferenceListener;
use OCA\Tables\Listener\UserDeletedListener;
use OCA\Tables\Reference\ContentReferenceProvider;
use OCA\Tables\Reference\LegacyReferenceProvider;
use OCA\Tables\Reference\ReferenceProvider;
use OCA\Tables\Search\SearchTablesProvider;
use OCP\AppFramework\App;
Expand All @@ -19,12 +17,7 @@
use OCP\AppFramework\Bootstrap\IRegistrationContext;
use OCP\Collaboration\Reference\RenderReferenceEvent;
use OCP\Collaboration\Resources\LoadAdditionalScriptsEvent;
use OCP\IConfig;
use OCP\Server;
use OCP\User\Events\BeforeUserDeletedEvent;
use Psr\Container\ContainerExceptionInterface;

use Psr\Container\NotFoundExceptionInterface;

class Application extends App implements IBootstrap {
public const APP_ID = 'tables';
Expand Down Expand Up @@ -52,17 +45,7 @@ public function register(IRegistrationContext $context): void {

$context->registerSearchProvider(SearchTablesProvider::class);

try {
/** @var IConfig $config */
$config = Server::get(IConfig::class);
if (version_compare($config->getSystemValueString('version', '0.0.0'), '26.0.0', '<')) {
$context->registerReferenceProvider(LegacyReferenceProvider::class);
} else {
$context->registerReferenceProvider(ReferenceProvider::class);
}
$context->registerReferenceProvider(ContentReferenceProvider::class);
} catch (NotFoundExceptionInterface|ContainerExceptionInterface $e) {
}
$context->registerReferenceProvider(ReferenceProvider::class);

$context->registerCapability(Capabilities::class);
}
Expand Down
67 changes: 0 additions & 67 deletions lib/Reference/LegacyReferenceProvider.php

This file was deleted.

0 comments on commit 61472fc

Please sign in to comment.