summaryrefslogtreecommitdiffstats
path: root/lib/Explore
diff options
context:
space:
mode:
authorSean Molenaar <sean@seanmolenaar.eu>2020-09-28 21:07:24 +0200
committerBenjamin Brahmer <info@b-brahmer.de>2020-09-29 13:02:03 +0200
commitbc01761221384c0bbac0297d38e85bcaa6286a9a (patch)
treebea5acc2db33186982ba94a4270c9eb277c8f0b3 /lib/Explore
parentd00d1ab2a28f428223e52b17052c072c64784016 (diff)
Fix repair step and test it
Signed-off-by: Sean Molenaar <sean@seanmolenaar.eu>
Diffstat (limited to 'lib/Explore')
-rw-r--r--lib/Explore/RecommendedSites.php11
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/Explore/RecommendedSites.php b/lib/Explore/RecommendedSites.php
index 504d63497..38fa510da 100644
--- a/lib/Explore/RecommendedSites.php
+++ b/lib/Explore/RecommendedSites.php
@@ -22,13 +22,20 @@ class RecommendedSites
* @param string $exploreDir the absolute path to where the recommendation
* config files lie without a trailing slash
*/
- public function __construct($exploreDir)
+ public function __construct(string $exploreDir)
{
$this->directory = $exploreDir;
}
- public function forLanguage($languageCode)
+ /**
+ * @param string $languageCode
+ *
+ * @return array
+ *
+ * @throws RecommendedSiteNotFoundException
+ */
+ public function forLanguage(string $languageCode)
{
$file = $this->directory . '/feeds.' . $languageCode . '.json';