Skip to content

Commit

Permalink
Issues-2734 - Fix comment on shrink buffer function
Browse files Browse the repository at this point in the history
  • Loading branch information
ali-ahsan-ali committed Jul 27, 2024
1 parent 45f6b06 commit 180b41f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/NIOCore/ByteBuffer-core.swift
Original file line number Diff line number Diff line change
Expand Up @@ -826,7 +826,7 @@ public struct ByteBuffer {
return true
}

/// Shrinks the buffers capacity to a `desiredCapacity` without altering readably bytes.
/// The `ByteBuffer` will successfully be shrunk if the requested capacity is less than the current capacity, and the requested capacity is more than the number of readable bytes in the buffer. If either condition is not true, the buffer will not be shrunk.
///
/// - Parameter desiredCapacity: The desired capacity for the buffers capacity to be shrunken to
/// - Returns: Bool indicating whether the buffer capacity has been shrunk to the desiredCapacity.
Expand Down

0 comments on commit 180b41f

Please sign in to comment.