Fixed "redefinition of unused 'foo' from line X" pyflakes warnings.

This commit is contained in:
Tim Graham 2013-10-10 11:07:48 -04:00
parent cec11a3336
commit adedc31072
12 changed files with 27 additions and 34 deletions

View file

@ -53,11 +53,11 @@ class ProjectState(object):
@classmethod
def from_app_cache(cls, app_cache):
"Takes in an AppCache and returns a ProjectState matching it"
models = {}
app_models = {}
for model in app_cache.get_models():
model_state = ModelState.from_model(model)
models[(model_state.app_label, model_state.name.lower())] = model_state
return cls(models)
app_models[(model_state.app_label, model_state.name.lower())] = model_state
return cls(app_models)
def __eq__(self, other):
if set(self.models.keys()) != set(other.models.keys()):