mirror of
https://github.com/YunoHost/yunorunner.git
synced 2024-09-03 20:05:52 +02:00
[mod] rename function for better reading
This commit is contained in:
parent
6e8a2201b1
commit
713851cadc
1 changed files with 2 additions and 2 deletions
4
run.py
4
run.py
|
@ -377,7 +377,7 @@ def subscribe(ws, channel):
|
|||
|
||||
|
||||
@app.websocket('/index-ws')
|
||||
async def index_ws(request, websocket):
|
||||
async def ws_index(request, websocket):
|
||||
subscribe(websocket, "jobs")
|
||||
|
||||
await websocket.send(ujson.dumps({
|
||||
|
@ -391,7 +391,7 @@ async def index_ws(request, websocket):
|
|||
|
||||
|
||||
@app.websocket('/job-<job_id>-ws')
|
||||
async def job_ws(request, websocket, job_id):
|
||||
async def ws_job(request, websocket, job_id):
|
||||
job = Job.select().where(Job.id == job_id)
|
||||
|
||||
if job.count == 0:
|
||||
|
|
Loading…
Add table
Reference in a new issue