Disable global chat except for admins. Add release notes.

This commit is contained in:
Andy Janata 2017-08-13 12:17:42 -07:00
parent 9679d0f330
commit 17ac4078d0
4 changed files with 24 additions and 19 deletions

View File

@ -87,21 +87,15 @@ HttpSession hSession = request.getSession(true);
If this is your first time playing, you may wish to read <a href="index.jsp">the changelog and
list of known issues</a>.
</p>
<p tabindex="0">Most recent update: 3 May 2015:</p>
<p tabindex="0">Most recent update: 13 August 2017:</p>
<ul>
<li>The game list automatically updates once per minute now, instead of several times per
second. You can still click the Refresh Games button in the top left corner at any time.</li>
<li>Chat flood protection has been made more strict.</li>
<li>Other back-end changes to attempt to get the AWS bill in control.</li>
<li><strong>All locally-stored custom card sets have been removed.</strong> You must use
Cardcast for custom card sets now.</li>
<li>The 5th and 6th Expansions, PAX Prime 2014 Panel, Ten Days or Whatever of Kwanzaa,
and Science packs have all been added.</li>
<li>Remaining known issues and high priority features:<ul>
<li>Leaving a game as a spectator doesn't work right.</li>
<li>Game owners still can't kick players from their game.</li>
<li>Actually saw a deadlock the other night, so that needs fixed.</li>
</ul></li>
<li><strong>Global chat is disabled.</strong> Far too spammy, far too shitty. Go shitpost
somewhere else, or at least take it to a game chat.</li>
<li>Added metrics logging. This will allow analysis over what cards are played often, and
regional trends. See the next bullet point for details. Your username and chat will
<strong>never</strong> be stored permanently.</li>
<li><a href="privacy.html"><strong>Hey, this is important:</strong> Read the privacy page for
details about what gameplay information is collected and how it's shared.</a></li>
</ul>
<div id="nickbox">
Nickname:

View File

@ -54,6 +54,15 @@ to, for instance, display the number of connected players.
</p>
<p>Recent Changes:</p>
<ul>
<li>13 August 2017:<ul>
<li><strong>Global chat is disabled.</strong> Far too spammy, far too shitty. Go shitpost
somewhere else, or at least take it to a game chat.</li>
<li>Added metrics logging. This will allow analysis over what cards are played often, and
regional trends. See the next bullet point for details. Your username and chat will
<strong>never</strong> be stored permanently.</li>
<li><a href="privacy.html"><strong>Hey, this is important:</strong> Read the privacy page for
details about what gameplay information is collected and how it's shared.</a></li>
</ul></li>
<li>3 May 2015:<ul>
<li>The game list automatically updates once per minute now, instead of several times per
second. You can still click the Refresh Games button in the top left corner at any time.</li>

View File

@ -96,6 +96,7 @@ cah.ajax.after_registered = function() {
$("#bottom").removeClass("hide");
// TODO once there are channels, this needs to specify the global channel
cah.Ajax.build(cah.$.AjaxOperation.NAMES).run();
cah.log.error("IMPORTANT: Global chat has been disabled.");
cah.GameList.instance.show();
cah.GameList.instance.update();
cah.longpoll.longPoll();

View File

@ -1,16 +1,16 @@
/**
* Copyright (c) 2012, Andy Janata
* All rights reserved.
*
*
* Redistribution and use in source and binary forms, with or without modification, are permitted
* provided that the following conditions are met:
*
*
* * Redistributions of source code must retain the above copyright notice, this list of conditions
* and the following disclaimer.
* * Redistributions in binary form must reproduce the above copyright notice, this list of
* conditions and the following disclaimer in the documentation and/or other materials provided
* with the distribution.
*
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
@ -46,7 +46,7 @@ import com.google.inject.Inject;
/**
* Handler for chat messages.
*
*
* @author Andy Janata (ajanata@socialgamer.net)
*/
public class ChatHandler extends Handler {
@ -74,7 +74,8 @@ public class ChatHandler extends Handler {
if (request.getParameter(AjaxRequest.MESSAGE) == null) {
return error(ErrorCode.NO_MSG_SPECIFIED);
} else if (wall && !user.isAdmin()) {
} else if (/* wall && */!user.isAdmin()) {
// Making global chat admin-only because it's hopeless
return error(ErrorCode.NOT_ADMIN);
} else {
final String message = request.getParameter(AjaxRequest.MESSAGE).trim();