From fccc4d8bec89a232d45003a46b11579625ea17a7 Mon Sep 17 00:00:00 2001 From: sta Date: Thu, 4 Feb 2016 15:05:23 +0900 Subject: [PATCH] [Modify] Polish it --- websocket-sharp/Server/WebSocketBehavior.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/websocket-sharp/Server/WebSocketBehavior.cs b/websocket-sharp/Server/WebSocketBehavior.cs index 5ae6c8f6..57690f36 100644 --- a/websocket-sharp/Server/WebSocketBehavior.cs +++ b/websocket-sharp/Server/WebSocketBehavior.cs @@ -4,7 +4,7 @@ * * The MIT License * - * Copyright (c) 2012-2015 sta.blockhead + * Copyright (c) 2012-2016 sta.blockhead * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -297,10 +297,10 @@ namespace WebSocketSharp.Server private string checkIfValidConnectionRequest (WebSocketContext context) { return _originValidator != null && !_originValidator (context.Origin) - ? "Invalid Origin header." - : _cookiesValidator != null && - !_cookiesValidator (context.CookieCollection, context.WebSocket.CookieCollection) - ? "Invalid Cookies." + ? "Includes no Origin header, or it has an invalid value." + : _cookiesValidator != null + && !_cookiesValidator (context.CookieCollection, context.WebSocket.CookieCollection) + ? "Includes no cookie, or an invalid cookie exists." : null; }