From 8a0ad07a2a237800ed0bf66c31ee7687bac0304a Mon Sep 17 00:00:00 2001 From: Oliver Wong Date: Fri, 15 May 2026 10:13:09 +0800 Subject: [PATCH] unify coding style --- .../Haptic/Handwritten/HandwrittenDefinitions.cs | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/Assets/Scripts/OCES/Haptic/Handwritten/HandwrittenDefinitions.cs b/Assets/Scripts/OCES/Haptic/Handwritten/HandwrittenDefinitions.cs index fa11f17..7b09ab3 100644 --- a/Assets/Scripts/OCES/Haptic/Handwritten/HandwrittenDefinitions.cs +++ b/Assets/Scripts/OCES/Haptic/Handwritten/HandwrittenDefinitions.cs @@ -31,15 +31,13 @@ namespace OCES.Haptic { if (bytes == null) return false; - using (MemoryStream memoryStream = new(bytes)) + using MemoryStream memoryStream = new(bytes); + using (BinaryReader br = new(memoryStream)) { - using (var br = new BinaryReader(memoryStream)) - { - data.DeSerialize(br); - br.Close(); - } - memoryStream.Close(); + data.DeSerialize(br); + br.Close(); } + memoryStream.Close(); return true; } }