Skip to content

Commit

Permalink
Remove duplicate checks
Browse files Browse the repository at this point in the history
  • Loading branch information
sonicaj committed Dec 29, 2023
1 parent a1b641c commit 127a73b
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions scale_build/bootstrap/cache.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,15 +56,10 @@ def mirror_cache_intact(self):

if intact:
self.restore_cache(self.chroot_basedir)
if os.path.exists(
os.path.join(self.chroot_basedir, 'etc/passwd')
) and os.path.exists(os.path.join(self.chroot_basedir, 'etc/group')):
for _, diff in compare_reference_files(cut_nonexistent_user_group_membership=True):
if diff:
intact = False
break
else:
intact = False
for _, diff in compare_reference_files(cut_nonexistent_user_group_membership=True):
if diff:
intact = False
break

# Remove the temporary restored cached directory
shutil.rmtree(self.chroot_basedir, ignore_errors=True)
Expand Down

0 comments on commit 127a73b

Please sign in to comment.