Do not use OCP\Util anymore - API not avaiable in Nextcloud 14.
[grauphel.git] / appinfo / app.php
index d78a9bb2b681c6001b88fa34e229e66563c7c2d6..1fb5551b75e37cf535338fe24179c1a6678f6827 100755 (executable)
@@ -3,11 +3,15 @@
     array( 
         'id' => 'grauphel',
         'order' => 2342,
     array( 
         'id' => 'grauphel',
         'order' => 2342,
-        'href' => \OCP\Util::linkToRoute('grauphel.gui.index'),
-        'icon' => \OCP\Util::imagePath('grauphel', 'app.svg'),
+        'href' => \OC::$server->getURLGenerator()->linkToRoute('grauphel.gui.index'),
+        'icon' => \OC::$server->getURLGenerator()->imagePath('grauphel', 'app.svg'),
         'name' => 'Tomboy notes'
     )
 );
         'name' => 'Tomboy notes'
     )
 );
-\OC_Search::registerProvider('OCA\Grauphel\Search\Provider');
+
+\OC::$server->getSearch()->registerProvider(
+    'OCA\Grauphel\Search\Provider', array('apps' => array('grauphel'))
+);
+
 \OCP\Util::addscript('grauphel', 'loader');
 ?>
 \OCP\Util::addscript('grauphel', 'loader');
 ?>