浏览代码

Always set lobby creator as referee

kiwec 4 月之前
父节点
当前提交
e5e879f516
共有 2 个文件被更改,包括 2 次插入1 次删除
  1. 2 0
      ranked.js
  2. 0 1
      website_api.js

+ 2 - 0
ranked.js

@@ -549,6 +549,8 @@ async function init_lobby(lobby, data, created_just_now) {
     // Lobbies are ScoreV1 - but we ignore the results and get the full score info from osu's API.
     await lobby.send(`!mp set 0 0 16`);
 
+    await lobby.send(`!mp addref #${lobby.data.creator_id}`);
+
     update_map_selection_query(lobby);
     await set_new_title(lobby);
   } else {

+ 0 - 1
website_api.js

@@ -435,7 +435,6 @@ async function register_routes(app) {
       try {
         console.info(`Creating lobby for ${lobby_data.creator}...`);
         lobby = await bancho.make(Config.IS_PRODUCTION ? `New o!RL lobby` : `test lobby`);
-        await lobby.send(`!mp addref #${req.signedCookies.user}`);
       } catch (err) {
         http_res.status(400).json({error: 'Could not create the lobby', details: err.message});
         return;