Set default Plex port
This commit is contained in:
+1
-1
@@ -2,6 +2,6 @@
|
||||
"theme": "light",
|
||||
"token": "",
|
||||
"server_url": "",
|
||||
"server_port": "",
|
||||
"server_port": "32400",
|
||||
"library": ""
|
||||
}
|
||||
+1
-1
@@ -32,7 +32,7 @@ async def login(
|
||||
user: str = Form(...),
|
||||
pw: str = Form(...),
|
||||
url: str = Form(...),
|
||||
port: str = Form(...),
|
||||
port: str = Form("32400"),
|
||||
library: str = Form(...)
|
||||
):
|
||||
config = load_config()
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
</div>
|
||||
<div class="mb-3">
|
||||
<label for="port" class="form-label">端口</label>
|
||||
<input type="text" class="form-control" id="port" name="port" placeholder="32400">
|
||||
<input type="text" class="form-control" id="port" name="port" value="32400">
|
||||
</div>
|
||||
<div class="mb-3">
|
||||
<label for="library" class="form-label">选择库</label>
|
||||
|
||||
@@ -2,7 +2,7 @@ from plexapi.myplex import MyPlexAccount
|
||||
from plexapi.server import PlexServer
|
||||
|
||||
|
||||
def connect_plex(config, username, password, url, port, library):
|
||||
def connect_plex(config, username, password, url, port="32400", library=""):
|
||||
"""Return a connected PlexServer instance and update config with token and server info."""
|
||||
token = config.get("token")
|
||||
if not token:
|
||||
|
||||
Reference in New Issue
Block a user