fixed language selection for end-of-game summary email.
[e-DoKo.git] / include / cancelgame.php
index a6a4fe97c57ba33c0c438c3782ef08aed3fa62bd..02b5a06fd0f4349d515995275ecb8daae6f7e07a 100644 (file)
@@ -1,5 +1,5 @@
 <?php
-/* Copyright 2006, 2007, 2008, 2009, 2010, 2011, 2012 Arun Persaud <arun@nubati.net>
+/* Copyright 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Arun Persaud <arun@nubati.net>
  *
  *   This file is part of e-DoKo.
  *
@@ -49,7 +49,7 @@ $gameid   = DB_get_gameid_by_hash($me);
 $myname   = DB_get_name('hash',$me);
 
 /* check if game really is old enough to be canceled */
-$r = DB_query_array("SELECT mod_date from Game WHERE id='$gameid' " );
+$r = DB_query_array("SELECT mod_date from Game WHERE id=".DB_quote_smart($gameid) );
 if(time()-strtotime($r[0]) > 60*60*24*30) /* = 1 month */
   {
     /* email to all players */