MCPcopy Create free account
hub / github.com/imgproxy/imgproxy / remove

Method remove

logger/buffer.go:100–104  ·  view source on GitHub ↗

remove removes the last n bytes from the buffer.

(n int)

Source from the content-addressed store, hash-verified

98
99// remove removes the last n bytes from the buffer.
100func (b *buffer) remove(n int) {
101 n = max(0, n)
102 trimTo := max(0, len(*b)-n)
103 *b = (*b)[:trimTo]
104}
105
106// removeNewline removes the trailing newline character from the buffer, if present.
107func (b *buffer) removeNewline() {

Callers 1

closeGroupMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected