Update paste.go

This commit is contained in:
Alexander-Ger-Reich
2025-09-28 13:23:59 +02:00
committed by GitHub
parent db719c32ad
commit 1499edd83c

View File

@@ -106,26 +106,6 @@ func (s *Service) Paste(c *gin.Context) {
for _, char := range req.Content {
key, ok := charMapLocal[char]
if !ok {
hex := string(char)
code := int(char)
for i := 12; i >= 0; i -= 4 {
digit := (code >> i) & 0xF
var c byte
if digit < 10 {
c = byte('0' + digit)
} else {
c = byte('A' + (digit - 10))
}
hex += string(c)
}
rsp.ErrRsp(c, -1, "unknown character: "+hex)
log.Debugf("unknown key '%c' (rune: %d)", char, char)
continue
}