Last fixes before release (#2027)
* Disable login button when a login is in-progress. This will help prevent spamming when internet is slow. * Fixed a bug where an empty space could cause an error when creating a library. * Apply Split Options throughout the codebase to add extra safe-guard on empty spaces and ensure trimming.
This commit is contained in:
parent
a28cd31ed8
commit
68c2577e15
9 changed files with 26 additions and 114 deletions
|
|
@ -195,7 +195,7 @@ public class SettingsController : BaseApiController
|
|||
{
|
||||
if (OsInfo.IsDocker) continue;
|
||||
// Validate IP addresses
|
||||
foreach (var ipAddress in updateSettingsDto.IpAddresses.Split(','))
|
||||
foreach (var ipAddress in updateSettingsDto.IpAddresses.Split(',', StringSplitOptions.TrimEntries | StringSplitOptions.RemoveEmptyEntries))
|
||||
{
|
||||
if (!IPAddress.TryParse(ipAddress.Trim(), out _)) {
|
||||
return BadRequest($"IP Address '{ipAddress}' is invalid");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue