OSDN Git Service

Merge branch '201311-ExcludeNonRatedPlayers'
[shogi-server/shogi-server.git] / shogi_server / game_result.rb
index 0dd90f1..a90289d 100644 (file)
@@ -1,7 +1,7 @@
 ## $Id$
 
 ## Copyright (C) 2004 NABEYA Kenichi (aka nanami@2ch)
-## Copyright (C) 2007-2008 Daigo Moriwaki (daigo at debian dot org)
+## Copyright (C) 2007-2012 Daigo Moriwaki (daigo at debian dot org)
 ##
 ## This program is free software; you can redistribute it and/or modify
 ## it under the terms of the GNU General Public License as published by
@@ -26,8 +26,8 @@ module ShogiServer # for a namespace
 #
 class MonitorObserver
   def update(game_result)
-    game_result.game.each_monitor do |monitor|
-      monitor.write_safe("##[MONITOR][%s] %s\n" % [game_result.game.game_id, game_result.result_type])
+    game_result.game.each_monitor do |monitor_handler|
+      monitor_handler.write_safe(game_result.game.game_id, game_result.result_type)
     end
   end
 end