Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
UltimaHoarder committed Jun 28, 2021
1 parent 7f48d16 commit d828d91
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions classes/prepare_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ def __init__(
self,
authed=None,
version=None,
old_content: dict = {},
temp_old_content: dict = {},
export=False,
reformat=False,
args={},
Expand All @@ -149,11 +149,11 @@ def __init__(self) -> None:
def __iter__(self):
for attr, value in self.__dict__.items():
yield attr, value
old_content2 = old_content
old_content2.pop("directories", None)
old_content = temp_old_content.copy()
old_content.pop("directories", None)
new_content = media_types(assign_states=assign_state)
for key, new_item in new_content:
old_item = old_content2.get(key)
old_item = old_content.get(key)
if not old_item:
continue
for old_key, old_item2 in old_item.items():
Expand Down
4 changes: 2 additions & 2 deletions helpers/db_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ def create_auth_array(item):
return auth_array


def get_or_create(session: Session, model, defaults=None, fbkwargs={}):
fbkwargs2 = fbkwargs
def get_or_create(session: Session, model, defaults=None, fbkwargs:dict={}):
fbkwargs2 = fbkwargs.copy()
instance = session.query(model).filter_by(**fbkwargs2).one_or_none()
if instance:
return instance, True
Expand Down

0 comments on commit d828d91

Please sign in to comment.