diff --git a/websocket-sharp/Ext.cs b/websocket-sharp/Ext.cs index 9e1fb8f7..2d259566 100644 --- a/websocket-sharp/Ext.cs +++ b/websocket-sharp/Ext.cs @@ -570,13 +570,15 @@ namespace WebSocketSharp return unquote ? val.Unquote () : val; } - internal static byte[] InternalToByteArray (this ushort value, ByteOrder order) + internal static byte[] InternalToByteArray ( + this ushort value, ByteOrder order + ) { - var bytes = BitConverter.GetBytes (value); + var ret = BitConverter.GetBytes (value); if (!order.IsHostOrder ()) - Array.Reverse (bytes); + Array.Reverse (ret); - return bytes; + return ret; } internal static byte[] InternalToByteArray (this ulong value, ByteOrder order)