From 2c66183b5e6e97ae67ed78d2b1a897dbb4273d90 Mon Sep 17 00:00:00 2001 From: godotg Date: Tue, 13 Aug 2024 10:57:11 +0800 Subject: [PATCH] style[golang]: replace space with tab --- .../main/resources/golang/ProtocolRegistrationTemplate.go | 6 +++--- .../resources/golang/ProtocolRegistrationTemplateEmpty.go | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/protocol/src/main/resources/golang/ProtocolRegistrationTemplate.go b/protocol/src/main/resources/golang/ProtocolRegistrationTemplate.go index 654302d2..35098547 100644 --- a/protocol/src/main/resources/golang/ProtocolRegistrationTemplate.go +++ b/protocol/src/main/resources/golang/ProtocolRegistrationTemplate.go @@ -4,7 +4,7 @@ func (protocol ${protocol_name}) ProtocolId() int16 { func (protocol ${protocol_name}) write(buffer *ByteBuffer, packet any) { if packet == nil { - buffer.WriteInt(0) + buffer.WriteInt(0) return } var message = packet.(*${protocol_name}) @@ -20,7 +20,7 @@ func (protocol ${protocol_name}) read(buffer *ByteBuffer) any { var beforeReadIndex = buffer.GetReadOffset() ${protocol_read_deserialization} if length > 0 { - buffer.SetReadOffset(beforeReadIndex + length) - } + buffer.SetReadOffset(beforeReadIndex + length) + } return packet } diff --git a/protocol/src/main/resources/golang/ProtocolRegistrationTemplateEmpty.go b/protocol/src/main/resources/golang/ProtocolRegistrationTemplateEmpty.go index 3f09d843..62dd2d22 100644 --- a/protocol/src/main/resources/golang/ProtocolRegistrationTemplateEmpty.go +++ b/protocol/src/main/resources/golang/ProtocolRegistrationTemplateEmpty.go @@ -4,7 +4,7 @@ func (protocol ${protocol_name}) ProtocolId() int16 { func (protocol ${protocol_name}) write(buffer *ByteBuffer, packet any) { if packet == nil { - buffer.WriteInt(0) + buffer.WriteInt(0) return } buffer.WriteInt(-1) @@ -18,7 +18,7 @@ func (protocol ${protocol_name}) read(buffer *ByteBuffer) any { } var beforeReadIndex = buffer.GetReadOffset() if length > 0 { - buffer.SetReadOffset(beforeReadIndex + length) - } + buffer.SetReadOffset(beforeReadIndex + length) + } return packet }