]> git.immae.eu Git - github/shaarli/Shaarli.git/blobdiff - application/bookmark/BookmarkFileService.php
New plugin hook: ability to add custom filters to Shaarli search engine
[github/shaarli/Shaarli.git] / application / bookmark / BookmarkFileService.php
index 8ea37427a02a6af364d6a1b79b0e5f921e2ebd0c..e64eeafbd98a30f2a0b50ace69357f268d9e2343 100644 (file)
@@ -15,6 +15,7 @@ use Shaarli\Formatter\BookmarkMarkdownFormatter;
 use Shaarli\History;
 use Shaarli\Legacy\LegacyLinkDB;
 use Shaarli\Legacy\LegacyUpdater;
+use Shaarli\Plugin\PluginManager;
 use Shaarli\Render\PageCacheManager;
 use Shaarli\Updater\UpdaterUtils;
 
@@ -40,6 +41,9 @@ class BookmarkFileService implements BookmarkServiceInterface
     /** @var ConfigManager instance */
     protected $conf;
 
+    /** @var PluginManager */
+    protected $pluginManager;
+
     /** @var History instance */
     protected $history;
 
@@ -57,6 +61,7 @@ class BookmarkFileService implements BookmarkServiceInterface
      */
     public function __construct(
         ConfigManager $conf,
+        PluginManager $pluginManager,
         History $history,
         Mutex $mutex,
         bool $isLoggedIn
@@ -95,7 +100,8 @@ class BookmarkFileService implements BookmarkServiceInterface
             }
         }
 
-        $this->bookmarkFilter = new BookmarkFilter($this->bookmarks, $this->conf);
+        $this->pluginManager = $pluginManager;
+        $this->bookmarkFilter = new BookmarkFilter($this->bookmarks, $this->conf, $this->pluginManager);
     }
 
     /**