remove(magnet): 删除磁力链接相关功能模块

- 移除 magnet_bp 蓝图及其路由配置
- 删除 app/__init__.py 中的 magnet_bp 导入和注册
- 移除 app/services/magnet_service.py 服务文件
- 从 requirements.txt 中删除 libtorrent 依赖
- 保留 Flask-CORS 但移除其他无关依赖项位置调整
This commit is contained in:
2026-06-10 18:57:07 +08:00
parent 6cbacab98b
commit 912eebddee
4 changed files with 2 additions and 24 deletions
+1 -2
View File
@@ -2,7 +2,7 @@ from flask import Flask
from flask_cors import CORS
from .extensions import db, migrate
from .config import DevelopmentConfig, ProductionConfig, TestingConfig
from .blueprints import torrent_bp, book_bp, music_bp, file_bp, video_bp, image_bp, asmr_bp, magnet_bp
from .blueprints import torrent_bp, book_bp, music_bp, file_bp, video_bp, image_bp, asmr_bp
def create_app(config_name="development"):
@@ -28,6 +28,5 @@ def create_app(config_name="development"):
app.register_blueprint(video_bp.bp, url_prefix='/api/video')
app.register_blueprint(image_bp.bp, url_prefix='/api/image')
app.register_blueprint(asmr_bp.bp, url_prefix='/api/asmr')
app.register_blueprint(magnet_bp.bp, url_prefix='/api/magnet')
return app
-11
View File
@@ -1,11 +0,0 @@
from flask import Blueprint, Response, jsonify
from app.services.magnet_service import MagnetService
bp = Blueprint("magnet", __name__)
@bp.route("/")
def index():
magnet_object = MagnetService()
return jsonify({"code": 200, "message": magnet_object.to_torrent()})
-9
View File
@@ -1,9 +0,0 @@
import requests
class MagnetService:
def __init__(self):
pass
def to_torrent(self):
pass
-1
View File
@@ -7,4 +7,3 @@ Flask-Migrate
Flask-SocketIO
Flask-SQLAlchemy
Flask-CORS
libtorrent