cloud sync: fix smartlog message for multiple checkouts

Summary:
the smartlog message notification about "cloud sync is running" was not working because srcrepo should be used instead of repo.
commit cloud is srcrepo based feature

Reviewed By: ikostia

Differential Revision: D9479775

fbshipit-source-id: a41852b86a8dea7c9d01ea0f31cecdcb0a2bc229
This commit is contained in:
Liubov Dmitrieva 2018-08-23 06:30:40 -07:00 committed by Facebook Github Bot
parent d5391483e7
commit 3e0958929c

View File

@ -860,7 +860,8 @@ def autosyncenabled(ui, _repo):
def backuplockcheck(ui, repo):
try:
lockmod.trylock(ui, repo.vfs, _backuplockname, 0, 0)
srcrepo = shareutil.getsrcrepo(repo)
lockmod.trylock(ui, srcrepo.vfs, _backuplockname, 0, 0)
except error.LockHeld as e:
if e.lockinfo.isrunning():
lockinfo = e.lockinfo