[Modify] Polish it

This commit is contained in:
sta 2018-10-07 20:14:15 +09:00
parent f350ac4078
commit 5c7a868514

View File

@ -134,7 +134,7 @@ namespace WebSocketSharp.Net
: -1; : -1;
} }
private static string htmlEncode (string s, bool attribute) private static string htmlEncode (string s, bool minimal)
{ {
var buff = new StringBuilder (); var buff = new StringBuilder ();
@ -148,7 +148,7 @@ namespace WebSocketSharp.Net
? "<" ? "<"
: c == '>' : c == '>'
? ">" ? ">"
: !attribute && c > 159 : !minimal && c > 159
? String.Format ("&#{0};", (int) c) ? String.Format ("&#{0};", (int) c)
: c.ToString () : c.ToString ()
); );