aboutsummaryrefslogtreecommitdiff
path: root/app/Services/ImportService.php
diff options
context:
space:
mode:
Diffstat (limited to 'app/Services/ImportService.php')
-rw-r--r--app/Services/ImportService.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/Services/ImportService.php b/app/Services/ImportService.php
index 973cd7825..635613475 100644
--- a/app/Services/ImportService.php
+++ b/app/Services/ImportService.php
@@ -67,8 +67,8 @@ class FreshRSS_Import_Service {
//Sort with categories first
usort($opml_elements, function ($a, $b) {
return strcmp(
- (isset($a['xmlUrl']) ? 'Z' : 'A') . $a['text'],
- (isset($b['xmlUrl']) ? 'Z' : 'A') . $b['text']);
+ (isset($a['xmlUrl']) ? 'Z' : 'A') . (isset($a['text']) ? $a['text'] : ''),
+ (isset($b['xmlUrl']) ? 'Z' : 'A') . (isset($b['text']) ? $b['text'] : ''));
});
foreach ($opml_elements as $elt) {
@@ -86,7 +86,7 @@ class FreshRSS_Import_Service {
} else {
$ok = false;
}
- } else {
+ } elseif (!empty($elt['text'])) {
// No xmlUrl? It should be a category!
$limit_reached = ($nb_cats >= $limits['max_categories']);
if (!FreshRSS_Context::$isCli && $limit_reached) {