diff options
author | Lukas Fleischer <archlinux@cryptocrack.de> | 2014-05-01 09:27:06 +0200 |
---|---|---|
committer | Lukas Fleischer <archlinux@cryptocrack.de> | 2014-05-01 09:29:55 +0200 |
commit | e161c4f94b75b26f115f6953cdc67a543cf89ec2 (patch) | |
tree | bbd2d674408903ba6879f5fd9685e10366d7de5c /web/lib/pkgfuncs.inc.php | |
parent | 05f88b28b8ed8941bd97537a3c31c4e766b61493 (diff) | |
download | aur-e161c4f94b75b26f115f6953cdc67a543cf89ec2.tar.gz aur-e161c4f94b75b26f115f6953cdc67a543cf89ec2.tar.xz |
Fix vote/notify link on the package details page
Call pkgbase_user_voted() and pkgbase_user_notify() using the package
base ID instead of using the package ID.
Fixes FS#40165.
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Diffstat (limited to 'web/lib/pkgfuncs.inc.php')
-rw-r--r-- | web/lib/pkgfuncs.inc.php | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/web/lib/pkgfuncs.inc.php b/web/lib/pkgfuncs.inc.php index f800e343..a6fa32e4 100644 --- a/web/lib/pkgfuncs.inc.php +++ b/web/lib/pkgfuncs.inc.php @@ -395,11 +395,12 @@ function pkg_name_is_blacklisted($name) { function pkg_get_details($id=0) { $dbh = DB::connect(); - $q = "SELECT Packages.*, PackageBases.Name AS BaseName, "; - $q.= "PackageBases.CategoryID, PackageBases.NumVotes, "; - $q.= "PackageBases.OutOfDateTS, PackageBases.SubmittedTS, "; - $q.= "PackageBases.ModifiedTS, PackageBases.SubmitterUID, "; - $q.= "PackageBases.MaintainerUID, PackageCategories.Category "; + $q = "SELECT Packages.*, PackageBases.ID AS BaseID, "; + $q.= "PackageBases.Name AS BaseName, PackageBases.CategoryID, "; + $q.= "PackageBases.NumVotes, PackageBases.OutOfDateTS, "; + $q.= "PackageBases.SubmittedTS, PackageBases.ModifiedTS, "; + $q.= "PackageBases.SubmitterUID, PackageBases.MaintainerUID, "; + $q.= "PackageCategories.Category "; $q.= "FROM Packages, PackageBases, PackageCategories "; $q.= "WHERE PackageBases.ID = Packages.PackageBaseID "; $q.= "AND PackageBases.CategoryID = PackageCategories.ID "; |