Skip to content
Snippets Groups Projects
Commit 3ce7e4e2 authored by Nicholas Christensen's avatar Nicholas Christensen
Browse files

more lowercase variables

parent 1f94b148
Branches
Tags
No related merge requests found
...@@ -167,21 +167,21 @@ class Taggable: ...@@ -167,21 +167,21 @@ class Taggable:
def _check_uniqueness(self): def _check_uniqueness(self):
class_set = set() class_set = set()
def _check_recursively(inClass, class_set): def _check_recursively(in_class, class_set):
# Termination condition # Termination condition
if issubclass(inClass, UniqueTag) and inClass is not UniqueTag: if issubclass(in_class, UniqueTag) and in_class is not UniqueTag:
if inClass in class_set: if in_class in class_set:
error_string = ("Two or more Tags are instances of {}." error_string = ("Two or more Tags are instances of {}."
" A Taggable object can only instantiate with one" " A Taggable object can only instantiate with one"
" instance of each UniqueTag sub-class.").format( " instance of each UniqueTag sub-class.").format(
inClass.__name__) in_class.__name__)
raise ValueError(error_string) raise ValueError(error_string)
else: else:
class_set.add(inClass) class_set.add(in_class)
# Recurse to all superclasses # Recurse to all superclasses
for c in inClass.__bases__: for c in in_class.__bases__:
_check_recursively(c, class_set) _check_recursively(c, class_set)
for tag in self.tags: for tag in self.tags:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment