Skip to content
Snippets Groups Projects
Commit 8601c70b authored by Henrik tom Wörden's avatar Henrik tom Wörden
Browse files

FIX: remove typos

parent b264e743
No related branches found
No related tags found
3 merge requests!91Release 0.3,!69Refactor Identifiable and caches,!67MAINT: introduce an identifiable class
Pipeline #30606 passed
...@@ -726,7 +726,7 @@ class Crawler(object): ...@@ -726,7 +726,7 @@ class Crawler(object):
# 2. Can it be identified via a path? # 2. Can it be identified via a path?
# 3. Is it in the cache of already checked Records? # 3. Is it in the cache of already checked Records?
# 4. Can it be checked on the remote server? # 4. Can it be checked on the remote server?
# 5. Does it have to be new since a needed referenc is missing? # 5. Does it have to be new since a needed reference is missing?
for i in reversed(range(len(flat))): for i in reversed(range(len(flat))):
record = flat[i] record = flat[i]
identifiable = self.identifiableAdapter.get_identifiable(record) identifiable = self.identifiableAdapter.get_identifiable(record)
...@@ -742,17 +742,17 @@ class Crawler(object): ...@@ -742,17 +742,17 @@ class Crawler(object):
del flat[i] del flat[i]
# 2. Can it be identified via a path? # 2. Can it be identified via a path?
elif record.path is not None: elif record.path is not None:
exiting = self._get_entity_by_path(record.path) existing = self._get_entity_by_path(record.path)
if exiting is None: if existing is None:
to_be_inserted.append(record) to_be_inserted.append(record)
self.add_to_remote_missing_cache(record) self.add_to_remote_missing_cache(record)
del flat[i] del flat[i]
else: else:
record.id = exiting.id record.id = existing.id
# TODO check the following copying of _size and _checksum # TODO check the following copying of _size and _checksum
# Copy over checksum and size too if it is a file # Copy over checksum and size too if it is a file
record._size = exiting._size record._size = existing._size
record._checksum = exiting._checksum record._checksum = existing._checksum
to_be_updated.append(record) to_be_updated.append(record)
self.add_to_remote_existing_cache(record) self.add_to_remote_existing_cache(record)
del flat[i] del flat[i]
...@@ -785,7 +785,7 @@ class Crawler(object): ...@@ -785,7 +785,7 @@ class Crawler(object):
del flat[i] del flat[i]
resolved_references = True resolved_references = True
# 5. Does it have to be new since a needed referenc is missing? # 5. Does it have to be new since a needed reference is missing?
# (Is it impossible to check this record because an identifiable references a # (Is it impossible to check this record because an identifiable references a
# missing record?) # missing record?)
elif self._has_missing_object_in_references(identifiable): elif self._has_missing_object_in_references(identifiable):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment