This repository was archived by the owner on Dec 5, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +11
-4
lines changed
src/UnityExtension/Assets/Editor/GitHub.Unity/UI Expand file tree Collapse file tree 1 file changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -251,19 +251,26 @@ private void MaybeUpdateData()
251251 currentBranch = string . Format ( "[{0}]" , Repository . CurrentBranchName ) ;
252252 }
253253
254- if ( currentStatusEntriesHasUpdate || currentLocksHasUpdate )
254+ if ( currentLocksHasUpdate )
255255 {
256- currentStatusEntriesHasUpdate = false ;
257- currentLocksHasUpdate = false ;
258-
259256 gitLocks = new HashSet < NPath > ( Repository . CurrentLocks . Select ( gitLock => gitLock . Path ) ) ;
257+ }
258+
259+ if ( currentStatusEntriesHasUpdate )
260+ {
260261 gitStatusEntries = Repository . CurrentChanges . Where ( x => x . Status != GitFileStatus . Ignored ) . ToList ( ) ;
261262
262263 changedFilesText = gitStatusEntries . Count == 0
263264 ? NoChangedFilesLabel
264265 : gitStatusEntries . Count == 1
265266 ? OneChangedFileLabel
266267 : String . Format ( ChangedFilesLabel , gitStatusEntries . Count ) ;
268+ }
269+
270+ if ( currentStatusEntriesHasUpdate || currentLocksHasUpdate )
271+ {
272+ currentStatusEntriesHasUpdate = false ;
273+ currentLocksHasUpdate = false ;
267274
268275 BuildTree ( ) ;
269276 }
You can’t perform that action at this time.
0 commit comments