Skip to content

Commit 446b967

Browse files
committed
Fix small issues
1 parent 6156af3 commit 446b967

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/libraries/Microsoft.Bcl.Memory/src/PACKAGE.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ byte[] data = Encoding.UTF8.GetBytes("Hello World!");
4343
Span<byte> encoded = new byte[Base64Url.GetEncodedLength(data.Length)];
4444
Base64Url.EncodeToUtf8(data, encoded, out int _, out int bytesWritten);
4545

46-
string encodedString = Encoding.UTF8.GetString(encoded[..bytesWritten]);
47-
Console.WriteLine($"Encoded: {encodedString}");
46+
string encodedString = Base64Url.EncodeToString(data);
47+
Console.WriteLine($"Encoded: {encodedString}");
4848
// Encoded: SGVsbG8gV29ybGQh
4949
5050
Span<byte> decoded = new byte[data.Length];
@@ -72,8 +72,8 @@ The main types provided by this library are:
7272
API documentation
7373

7474
* [System.Index](https://learn.microsoft.com/dotnet/api/system.index)
75-
* [System.Range](https://learn.microsoft.com/en-us/dotnet/api/system.range)
76-
* [System.Buffers.Text](https://learn.microsoft.com/dotnet/api/system.buffers.text)
75+
* [System.Range](https://learn.microsoft.com/dotnet/api/system.range)
76+
* [System.Buffers.Text.Base64Url](https://learn.microsoft.com/dotnet/api/system.buffers.text.base64url)
7777

7878
## Feedback & Contributing
7979

0 commit comments

Comments
 (0)