Skip to content

Commit

Permalink
removed redundant where clause borgbase#1942
Browse files Browse the repository at this point in the history
  • Loading branch information
TheLazron committed Mar 6, 2024
1 parent baf07a5 commit 164c906
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/vorta/profile_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ def to_db(self, overwrite_profile=False, overwrite_settings=True):
# Set the profile ids to be match new profile
for source in self._profile_dict['SourceFileModel']:
source['profile'] = self.id
for source in SourceFileModel.select().where(SourceFileModel.profile == source['profile']):
for source in SourceFileModel.select():
SourceFileModel.delete_by_id(source)
SourceFileModel.insert_many(self._profile_dict['SourceFileModel']).execute()

Expand Down

0 comments on commit 164c906

Please sign in to comment.