Skip to content

Commit 87f072e

Browse files
committed
Fix legacy changes
1 parent 7081687 commit 87f072e

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

mergin/client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -876,8 +876,8 @@ def push_project(self, directory):
876876
:param directory: Project's directory
877877
:type directory: String
878878
"""
879-
blocking_job, non_blocking_job = push_project_async(self, directory)
880-
for job in [blocking_job, non_blocking_job]:
879+
jobs = push_project_async(self, directory)
880+
for job in jobs:
881881
if job is None:
882882
return # there is nothing to push (or we only deleted some files)
883883
push_project_wait(job)

mergin/test/test_client.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -393,8 +393,9 @@ def test_cancel_push(mc):
393393
assert next((f for f in push_changes["updated"] if f["path"] == f_updated), None)
394394

395395
# start pushing and then cancel the job
396-
job, _ = push_project_async(mc, project_dir)
397-
push_project_cancel(job)
396+
jobs = push_project_async(mc, project_dir)
397+
for job in jobs:
398+
push_project_cancel(job)
398399

399400
# if cancelled properly, we should be now able to do the push without any problem
400401
mc.push_project(project_dir)

0 commit comments

Comments
 (0)