summaryrefslogtreecommitdiffstats
path: root/main/models.py
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2012-08-15 20:26:23 -0500
committerDan McGee <dan@archlinux.org>2012-08-15 20:26:26 -0500
commit04066d190efddaf890d8573a3fbf4fd1706cb51f (patch)
treed5bcfde0700e72f34f19e63c90a3cbff0f46a6b2 /main/models.py
parent2e9094630b5117575f899f068046c6e1021387a1 (diff)
downloadarchweb-04066d190efddaf890d8573a3fbf4fd1706cb51f.tar.gz
archweb-04066d190efddaf890d8573a3fbf4fd1706cb51f.zip
Ensure reverse conflicts match architecture if applicable
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'main/models.py')
-rw-r--r--main/models.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/main/models.py b/main/models.py
index 95e3c42b..202e7fa6 100644
--- a/main/models.py
+++ b/main/models.py
@@ -291,6 +291,10 @@ class Package(models.Model):
Returns a list of packages with conflicts against this package.
"""
pkgs = Package.objects.filter(conflicts__name=self.pkgname)
+ if not self.arch.agnostic:
+ # make sure we match architectures if possible
+ pkgs = pkgs.filter(arch__in=self.applicable_arches())
+
alpm = AlpmAPI()
if not alpm.available:
return pkgs