mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-12-22 08:45:23 +03:00
Use new Random.Shared instead of creating new instances
This commit is contained in:
@@ -316,7 +316,7 @@ namespace Jellyfin.Api.Controllers
|
||||
byte[] buffer = ArrayPool<byte>.Shared.Rent(size);
|
||||
try
|
||||
{
|
||||
new Random().NextBytes(buffer);
|
||||
Random.Shared.NextBytes(buffer);
|
||||
return File(buffer, MediaTypeNames.Application.Octet);
|
||||
}
|
||||
finally
|
||||
|
||||
Reference in New Issue
Block a user