@@ -207,14 +207,18 @@ public function create_db(array $data)
207207 }
208208
209209 // Init permissions
210- Container::get ('perms ' )->addParent (4 , array (3 ));
211- Container::get ('perms ' )->addParent (2 , array (3 ,4 ));
212- Container::get ('perms ' )->addParent (1 , array (2 ,3 ,4 ));
210+ // TODO: Reuse groups inheritance later ?
211+ // Container::get('perms')->addParent(4, array(3));
212+ // Container::get('perms')->addParent(2, array(3,4));
213+ // Container::get('perms')->addParent(1, array(2,3,4));
214+ // Container::get('perms')->allowGroup(3, array('board.read', 'users.view', 'search.topics', 'search.users'));
215+ // Container::get('perms')->allowGroup(4, array('topic.reply', 'topic.post', 'topic.delete', 'post.delete', 'post.edit', 'post.links', 'email.send'));
216+ // Container::get('perms')->allowGroup(2, array('mod.is_mod', 'mod.edit_users', 'mod.rename_users', 'mod.change_passwords', 'mod.promote_users', 'mod.ban_users', 'user.set_title'));
213217
214218 Container::get ('perms ' )->allowGroup (3 , array ('board.read ' , 'users.view ' , 'search.topics ' , 'search.users ' ));
215- Container::get ('perms ' )->allowGroup (4 , array ('topic.reply ' , 'topic.post ' , 'topic.delete ' , 'post.delete ' , 'post.edit ' , 'post.links ' , 'email.send ' ));
216- Container::get ('perms ' )->allowGroup (2 , array ('modpanel.* ' , 'mod.is_mod ' , 'mod.edit_users ' , 'mod.rename_users ' , 'mod.change_passwords ' , 'mod.promote_users ' , 'mod.ban_users ' , ' user.set_title ' ));
217- Container::get ('perms ' )->allowGroup (1 , array ('board. * ' ));
219+ Container::get ('perms ' )->allowGroup (4 , array ('board.read ' , ' users.view ' , ' search.topics ' , ' search.users ' , ' topic.reply ' , 'topic.post ' , 'topic.delete ' , 'post.delete ' , 'post.edit ' , 'post.links ' , 'email.send ' ));
220+ Container::get ('perms ' )->allowGroup (2 , array ('board.read ' , 'users.view ' , ' user.set_title ' , ' search.topics ' , ' search.users ' , ' topic.reply ' , ' topic.post ' , ' topic.delete ' , ' post.delete ' , ' post.edit ' , ' post.links ' , ' email.send ' , ' mod.is_mod ' , 'mod.edit_users ' , 'mod.rename_users ' , 'mod.change_passwords ' , 'mod.promote_users ' , 'mod.ban_users ' ));
221+ Container::get ('perms ' )->allowGroup (1 , array ('* ' ));
218222 // Init preferences
219223 Container::get ('prefs ' )->set (array (
220224 'post.min_interval ' => 60 ,
0 commit comments