mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
Bug in uploading PKGBUILDs and aur schema
This fixes a bug where TUs and devs couldn't upload packages because the query would have an extra column in it to mark the pkgbuild safe automatically, guessing it got missed when the safe flags were removed. Also fixes a screw up I made with the schema file when I added the tables for the voting app. Signed-off-by: Callan Barrett <wizzomafizzo@gmail.com>
This commit is contained in:
parent
8c94552042
commit
ce225727f6
2 changed files with 2 additions and 5 deletions
|
@ -223,12 +223,12 @@ CREATE TABLE IF NOT EXISTS TU_VoteInfo (
|
||||||
No tinyint(3) unsigned NOT NULL default '0',
|
No tinyint(3) unsigned NOT NULL default '0',
|
||||||
Abstain tinyint(3) unsigned NOT NULL default '0',
|
Abstain tinyint(3) unsigned NOT NULL default '0',
|
||||||
PRIMARY KEY (ID)
|
PRIMARY KEY (ID)
|
||||||
)
|
);
|
||||||
|
|
||||||
-- Individual vote records
|
-- Individual vote records
|
||||||
--
|
--
|
||||||
CREATE TABLE IF NOT EXISTS TU_Votes (
|
CREATE TABLE IF NOT EXISTS TU_Votes (
|
||||||
VoteID int(10) unsigned NOT NULL,
|
VoteID int(10) unsigned NOT NULL,
|
||||||
UserID int(10) unsigned NOT NULL
|
UserID int(10) unsigned NOT NULL
|
||||||
)
|
);
|
||||||
|
|
||||||
|
|
|
@ -486,9 +486,6 @@ if ($_COOKIE["AURSID"]) {
|
||||||
$q.= mysql_real_escape_string($new_pkgbuild['pkgdesc'])."', '";
|
$q.= mysql_real_escape_string($new_pkgbuild['pkgdesc'])."', '";
|
||||||
$q.= mysql_real_escape_string($new_pkgbuild['url']);
|
$q.= mysql_real_escape_string($new_pkgbuild['url']);
|
||||||
$q.= "', 2, ";
|
$q.= "', 2, ";
|
||||||
if (account_from_sid($_COOKIE["AURSID"]) == "Trusted User" || account_from_sid($_COOKIE["AURSID"]) == "Developer") {
|
|
||||||
$q.= "1, ".uid_from_sid($_COOKIE["AURSID"]).", ";
|
|
||||||
}
|
|
||||||
$q.= "UNIX_TIMESTAMP(), ";
|
$q.= "UNIX_TIMESTAMP(), ";
|
||||||
$q.= uid_from_sid($_COOKIE["AURSID"]).", ";
|
$q.= uid_from_sid($_COOKIE["AURSID"]).", ";
|
||||||
$q.= uid_from_sid($_COOKIE["AURSID"]).", '";
|
$q.= uid_from_sid($_COOKIE["AURSID"]).", '";
|
||||||
|
|
Loading…
Add table
Reference in a new issue