Further fixes (missing parameters and imports);
Thank you. roughnecks.
This commit is contained in:
parent
5fe4e3b211
commit
d9446e63f1
4 changed files with 6 additions and 6 deletions
|
@ -31,7 +31,7 @@ from slixfeed.config import Config
|
||||||
import slixfeed.fetch as fetch
|
import slixfeed.fetch as fetch
|
||||||
from slixfeed.log import Logger,Message
|
from slixfeed.log import Logger,Message
|
||||||
import slixfeed.sqlite as sqlite
|
import slixfeed.sqlite as sqlite
|
||||||
from slixfeed.utilities import DateAndTime, Html, MD, String, Url, Utilities
|
from slixfeed.utilities import Database, DateAndTime, Html, MD, String, Url, Utilities
|
||||||
from slixmpp.xmlstream import ET
|
from slixmpp.xmlstream import ET
|
||||||
import sys
|
import sys
|
||||||
from urllib.parse import urlsplit
|
from urllib.parse import urlsplit
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
__version__ = '0.1.106'
|
__version__ = '0.1.107'
|
||||||
__version_info__ = (0, 1, 106)
|
__version_info__ = (0, 1, 107)
|
||||||
|
|
|
@ -314,7 +314,7 @@ class XmppChat:
|
||||||
'Try: md or opml')
|
'Try: md or opml')
|
||||||
case _ if command_lowercase.startswith('feeds'):
|
case _ if command_lowercase.startswith('feeds'):
|
||||||
query = command[6:]
|
query = command[6:]
|
||||||
result, number = XmppCommands.list_feeds(db_file, query)
|
result, number = XmppCommands.list_feeds(self.dir_config, db_file, query)
|
||||||
if number:
|
if number:
|
||||||
if query:
|
if query:
|
||||||
first_line = f'Subscriptions containing "{query}":\n\n```\n'
|
first_line = f'Subscriptions containing "{query}":\n\n```\n'
|
||||||
|
|
|
@ -514,7 +514,7 @@ class XmppCommands:
|
||||||
return message
|
return message
|
||||||
|
|
||||||
|
|
||||||
def list_feeds(db_file, query=None):
|
def list_feeds(dir_config, db_file, query=None):
|
||||||
if query:
|
if query:
|
||||||
feeds = sqlite.search_feeds(db_file, query)
|
feeds = sqlite.search_feeds(db_file, query)
|
||||||
else:
|
else:
|
||||||
|
@ -528,7 +528,7 @@ class XmppCommands:
|
||||||
elif query:
|
elif query:
|
||||||
message = f"No feeds were found for: {query}"
|
message = f"No feeds were found for: {query}"
|
||||||
else:
|
else:
|
||||||
url = Utilities.pick_a_feed()
|
url = Utilities.pick_a_feed(dir_config)
|
||||||
message = ('List of subscriptions is empty. '
|
message = ('List of subscriptions is empty. '
|
||||||
'To add a feed, send a URL.\n'
|
'To add a feed, send a URL.\n'
|
||||||
'Featured news: *{}*\n{}'
|
'Featured news: *{}*\n{}'
|
||||||
|
|
Loading…
Reference in a new issue