summaryrefslogtreecommitdiffstats
path: root/dependencyinjection
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2013-09-25 23:09:04 +0200
committerRobin Appelman <icewind@owncloud.com>2013-09-25 23:23:14 +0200
commitec60b879acb1ffb15f91b0266b1301f234828b1f (patch)
tree38d6efcf1eb7edc6e9cbcca9de4d0fe70677580a /dependencyinjection
parent4f7dfef8831da88395f03913142925cae6aab747 (diff)
add article enhancer for twogag
Diffstat (limited to 'dependencyinjection')
-rw-r--r--dependencyinjection/dicontainer.php10
1 files changed, 10 insertions, 0 deletions
diff --git a/dependencyinjection/dicontainer.php b/dependencyinjection/dicontainer.php
index 2669336dc..58f406bd7 100644
--- a/dependencyinjection/dicontainer.php
+++ b/dependencyinjection/dicontainer.php
@@ -65,6 +65,7 @@ use \OCA\News\Utility\ArticleEnhancer\CyanideAndHappinessEnhancer;
use \OCA\News\Utility\ArticleEnhancer\ThemeRepublicEnhancer;
use OCA\News\Utility\ArticleEnhancer\CADEnhancer;
use OCA\News\Utility\ArticleEnhancer\PennyArcadeEnhancer;
+use OCA\News\Utility\ArticleEnhancer\TwoGAGEnhancer;
use \OCA\News\Middleware\CORSMiddleware;
@@ -265,6 +266,7 @@ class DIContainer extends BaseContainer {
$enhancer->registerEnhancer('themerepublic.net', $c['ThemeRepublicEnhancer']);
$enhancer->registerEnhancer('cad-comic.com', $c['CADEnhancer']);
$enhancer->registerEnhancer('penny-arcade.com', $c['PennyArcadeEnhancer']);
+ $enhancer->registerEnhancer('twogag.com', $c['TwoGAGEnhancer']);
return $enhancer;
});
@@ -305,6 +307,14 @@ class DIContainer extends BaseContainer {
);
});
+ $this['TwoGAGEnhancer'] = $this->share(function($c){
+ return new TwoGAGEnhancer(
+ $c['SimplePieFileFactory'],
+ $c['HTMLPurifier'],
+ $c['feedFetcherTimeout']
+ );
+ });
+
$this['Fetcher'] = $this->share(function($c){
$fetcher = new Fetcher();