diff --git a/src/ViewModels/LFSLocks.cs b/src/ViewModels/LFSLocks.cs index a09e7d1e..e462a069 100644 --- a/src/ViewModels/LFSLocks.cs +++ b/src/ViewModels/LFSLocks.cs @@ -80,21 +80,23 @@ namespace SourceGit.ViewModels private void UpdateVisibleLocks() { + var visible = new List(); + if (!_showOnlyMyLocks) { - VisibleLocks = _cachedLocks; + foreach (var lfsLock in _cachedLocks) + visible.Add(lfsLock); } else { - var visible = new List(); foreach (var lfsLock in _cachedLocks) { if (lfsLock.User == _userName) visible.Add(lfsLock); } - - VisibleLocks = visible; } + + VisibleLocks = visible; } private string _repo;