14 lines
327 B
Python
14 lines
327 B
Python
|
from flask import jsonify
|
||
|
from app.services.torrents import initiate_config
|
||
|
from . import api_bp
|
||
|
|
||
|
@api_bp.route("/api/config/")
|
||
|
def config_route():
|
||
|
config = initiate_config()
|
||
|
|
||
|
config = dict(config.app_config)
|
||
|
for section in config.keys():
|
||
|
config[section] = dict(config[section])
|
||
|
|
||
|
return jsonify(config)
|