--- a/netserver/HWProto.hs Fri Oct 31 14:30:08 2008 +0000
+++ b/netserver/HWProto.hs Fri Oct 31 14:35:59 2008 +0000
@@ -219,7 +219,10 @@
if not $ isMaster client then
(noChangeClients, noChangeRooms, answerNotMaster)
else
- (noChangeClients, modifyRoom $ modifyTeam clRoom team{teamcolor = newColor}, answerTeamColor teamName newColor)
+ if noSuchTeam then
+ (noChangeClients, noChangeRooms, answerBadParam)
+ else
+ (noChangeClients, modifyRoom $ modifyTeam clRoom team{teamcolor = newColor}, answerTeamColor teamName newColor)
where
noSuchTeam = isNothing findTeam
team = fromJust findTeam