Merge pull request #1414 from deadsurgeon42/general-devel
Add banning user and ban date fields to ban info and list endpoints
This commit is contained in:
commit
33178ad2b3
1 changed files with 5 additions and 1 deletions
|
|
@ -706,6 +706,8 @@ namespace TShockAPI
|
|||
return new RestObject() {
|
||||
{"name", null == ban.Name ? "" : ban.Name},
|
||||
{"ip", null == ban.IP ? "" : ban.IP},
|
||||
{"banning_user", null == ban.BanningUser ? "" : ban.BanningUser},
|
||||
{"date", null == ban.BanDateTime ? "" : ban.BanDateTime.Value.ToString()},
|
||||
{"reason", null == ban.Reason ? "" : ban.Reason},
|
||||
};
|
||||
}
|
||||
|
|
@ -724,6 +726,8 @@ namespace TShockAPI
|
|||
{
|
||||
{"name", null == ban.Name ? "" : ban.Name},
|
||||
{"ip", null == ban.IP ? "" : ban.IP},
|
||||
{"banning_user", null == ban.BanningUser ? "" : ban.BanningUser},
|
||||
{"date", null == ban.BanDateTime ? "" : ban.BanDateTime.Value.ToString()},
|
||||
{"reason", null == ban.Reason ? "" : ban.Reason},
|
||||
}
|
||||
);
|
||||
|
|
@ -735,7 +739,7 @@ namespace TShockAPI
|
|||
#endregion
|
||||
|
||||
#region Rest World Methods
|
||||
|
||||
|
||||
[Route("/v2/world/autosave/state/{state}")]
|
||||
[Permission(RestPermissions.restcfg)]
|
||||
[Verb("state", "The status for autosave.", typeof(bool))]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue