diff options
author | Yorhel <git@yorhel.nl> | 2020-04-15 11:53:38 +0200 |
---|---|---|
committer | Yorhel <git@yorhel.nl> | 2020-04-15 11:53:40 +0200 |
commit | be5ee198129301d84912380ed8d1636ad32f68b3 (patch) | |
tree | d02840ee97c05818556f886e69bcc5783b44c229 /util/vndb.pl | |
parent | 5a3a446b0530632942c577edbf10e9c7c2fb6fa9 (diff) |
SQL: Split "perm" column into multiple booleans
This simplifies several actions and makes permission checks more
obvious. This is also yack shaving for another feature I've been
planning to add: boardmods should be able to set other users' "board"
permission, tagmods for tags, etc. So that partial user bans don't need
the full "usermod" permission.
Diffstat (limited to 'util/vndb.pl')
-rwxr-xr-x | util/vndb.pl | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/util/vndb.pl b/util/vndb.pl index 3a7dd714..84398ca9 100755 --- a/util/vndb.pl +++ b/util/vndb.pl @@ -27,8 +27,6 @@ tuwf->{skins} = { map +($_ => [ $skin->get($_, 'name'), $skin->get($_, 'userid') tuwf->{scr_size} = [ 136, 102 ]; # w*h of screenshot thumbnails tuwf->{ch_size} = [ 256, 300 ]; # max. w*h of char images tuwf->{cv_size} = [ 256, 400 ]; # max. w*h of cover images -tuwf->{permissions} = {qw| board 1 boardmod 2 edit 4 tag 16 dbmod 32 tagmod 64 usermod 128 |}; -tuwf->{default_perm} = 1+4+16; # Keep synchronised with the default value of users.perm tuwf->{$_} = config->{$_} for keys %{ config() }; TUWF::set %{ config->{tuwf} }; |