Skip to content

Commit

Permalink
[cli] Handle server not connected situation in status command.
Browse files Browse the repository at this point in the history
  • Loading branch information
killing committed Aug 20, 2015
1 parent 6ec92f1 commit 40607f4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/seaf-cli
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,9 @@ def seaf_status(args):
continue

t = seafile_rpc.get_repo_sync_task(repo.id)
if t.state == "error":
if not t:
print "%s\twaiting for sync" % repo.name
elif t.state == "error":
print "%s\t%s" % (repo.name, t.error)
else:
print "%s\t%s" % (repo.name, t.state)
Expand Down

0 comments on commit 40607f4

Please sign in to comment.