Enable NRT on account creation classes

This commit is contained in:
Dean Herbert
2023-01-13 15:20:18 +09:00
parent 6daa37bd3e
commit 5658c3a123

View File

@ -1,17 +1,16 @@
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence. // Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text. // See the LICENCE file in the repository root for full licence text.
#nullable disable using System;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace osu.Game.Online.API namespace osu.Game.Online.API
{ {
public class RegistrationRequest : OsuWebRequest public class RegistrationRequest : OsuWebRequest
{ {
internal string Username; internal string Username = string.Empty;
internal string Email; internal string Email = string.Empty;
internal string Password; internal string Password = string.Empty;
protected override void PrePerform() protected override void PrePerform()
{ {
@ -24,18 +23,18 @@ namespace osu.Game.Online.API
public class RegistrationRequestErrors public class RegistrationRequestErrors
{ {
public UserErrors User; public UserErrors? User;
public class UserErrors public class UserErrors
{ {
[JsonProperty("username")] [JsonProperty("username")]
public string[] Username; public string[] Username = Array.Empty<string>();
[JsonProperty("user_email")] [JsonProperty("user_email")]
public string[] Email; public string[] Email = Array.Empty<string>();
[JsonProperty("password")] [JsonProperty("password")]
public string[] Password; public string[] Password = Array.Empty<string>();
} }
} }
} }