mirror of
https://github.com/spl0k/supysonic.git
synced 2024-12-22 08:56:17 +00:00
Chat as feature
This commit is contained in:
parent
c6b197689a
commit
84c1582446
@ -212,7 +212,12 @@ if config.getbool('features', 'rating', True):
|
|||||||
else:
|
else:
|
||||||
app.add_url_rule('/rest/setRating.view', view_func = disabled_api_feature, methods = [ 'GET', 'POST' ])
|
app.add_url_rule('/rest/setRating.view', view_func = disabled_api_feature, methods = [ 'GET', 'POST' ])
|
||||||
|
|
||||||
from .chat import *
|
if config.getbool('features', 'chat', True):
|
||||||
|
from .chat import *
|
||||||
|
else:
|
||||||
|
app.add_url_rule('/rest/getChatMessages.view', view_func = disabled_api_feature, methods = [ 'GET', 'POST' ])
|
||||||
|
app.add_url_rule('/rest/addChatMessage.view', view_func = disabled_api_feature, methods = [ 'GET', 'POST' ])
|
||||||
|
|
||||||
from .search import *
|
from .search import *
|
||||||
from .playlists import *
|
from .playlists import *
|
||||||
|
|
||||||
|
3
db.py
3
db.py
@ -368,7 +368,8 @@ if config.getbool('features', 'rating', True):
|
|||||||
user = relationship('User')
|
user = relationship('User')
|
||||||
rated = relationship('Track')
|
rated = relationship('Track')
|
||||||
|
|
||||||
class ChatMessage(Base):
|
if config.getbool('features', 'chat', True):
|
||||||
|
class ChatMessage(Base):
|
||||||
__tablename__ = 'chat_message'
|
__tablename__ = 'chat_message'
|
||||||
|
|
||||||
id = UUID.gen_id_column()
|
id = UUID.gen_id_column()
|
||||||
|
Loading…
Reference in New Issue
Block a user