From 6ff1efe0d07e24e9fb2db199c308c6cbed51e578 Mon Sep 17 00:00:00 2001 From: Yorhel Date: Thu, 23 Dec 2010 12:51:35 +0100 Subject: Converted the show_list pref. to users_prefs and inverted the value In the users_prefs table, the default value should evaluate to 'false' in Perl, so show_list had to be inverted to hide_list. --- util/sql/schema.sql | 1 - util/updates/update_2.16.sql | 3 +++ 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'util') diff --git a/util/sql/schema.sql b/util/sql/schema.sql index 8826a01e..638191c3 100644 --- a/util/sql/schema.sql +++ b/util/sql/schema.sql @@ -266,7 +266,6 @@ CREATE TABLE users ( rank smallint NOT NULL DEFAULT 3, passwd bytea NOT NULL DEFAULT '', registered timestamptz NOT NULL DEFAULT NOW(), - show_list boolean NOT NULL DEFAULT TRUE, c_votes integer NOT NULL DEFAULT 0, c_changes integer NOT NULL DEFAULT 0, ip inet NOT NULL DEFAULT '0.0.0.0', diff --git a/util/updates/update_2.16.sql b/util/updates/update_2.16.sql index a0678fd3..b401a7a4 100644 --- a/util/updates/update_2.16.sql +++ b/util/updates/update_2.16.sql @@ -65,8 +65,11 @@ INSERT INTO users_prefs (uid, key, value) SELECT id, 'customcss', customcss FROM users WHERE customcss <> ''; UNION SELECT id, 'show_nsfw'::prefs_key, '1' FROM users WHERE show_nsfw; + UNION + SELECT id, 'hide_list'::prefs_key, '1' FROM users WHERE NOT show_list; ALTER TABLE users DROP COLUMN skin; ALTER TABLE users DROP COLUMN customcss; ALTER TABLE users DROP COLUMN show_nsfw; +ALTER TABLE users DROP COLUMN show_list; -- cgit v1.2.3