diff options
author | Dan McGee <dan@archlinux.org> | 2012-03-26 19:33:28 +0200 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2012-03-26 19:33:28 +0200 |
commit | 611e30172ae8db58fc2f6146fd1bee428e55ea6a (patch) | |
tree | 0e4630d36639d6f6f25e861803d35f48301de672 /main | |
parent | 493092f88f03ae7ec385f76abeeb51516ff888e3 (diff) | |
download | archweb-611e30172ae8db58fc2f6146fd1bee428e55ea6a.tar.gz archweb-611e30172ae8db58fc2f6146fd1bee428e55ea6a.tar.xz |
Rename 'packagedepend_set' attribute to 'depends'
We do this for every other related package attribute, so do it here too.
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'main')
-rw-r--r-- | main/models.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/main/models.py b/main/models.py index 289cbb8..34cbcd1 100644 --- a/main/models.py +++ b/main/models.py @@ -288,7 +288,7 @@ class Package(models.Model): if not self.arch.agnostic: arches = self.applicable_arches() # TODO: we can use list comprehension and an 'in' query to make this more effective - for dep in self.packagedepend_set.order_by('optional', 'depname'): + for dep in self.depends.order_by('optional', 'depname'): pkg = dep.get_best_satisfier(arches, testing=self.repo.testing, staging=self.repo.staging) providers = None @@ -391,7 +391,7 @@ class PackageFile(models.Model): db_table = 'package_files' class PackageDepend(models.Model): - pkg = models.ForeignKey(Package) + pkg = models.ForeignKey(Package, related_name='depends') depname = models.CharField(max_length=255, db_index=True) depvcmp = models.CharField(max_length=255, default='') optional = models.BooleanField(default=False) |