Code Style
Fixed an indent.
This commit is contained in:
parent
39c5401cdb
commit
5e3dca5ce2
@ -23,8 +23,7 @@ public class SocketMessageController : ControllerBase
|
|||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (!this.CanTokenRequest(out long ID, out IActionResult? toc) && toc != null) return toc;
|
if (!this.CanTokenRequest(out long ID, out IActionResult? toc) && toc != null) return toc;
|
||||||
if (Luski.HasAccessToChannel(ID, data.ChannelID, ServerPermissions.SendMessages))
|
if (!Luski.HasAccessToChannel(ID, data.ChannelID, ServerPermissions.SendMessages)) return this.ResponseToResult(new HTTPResponse() { error = ErrorCode.Forbidden });
|
||||||
{
|
|
||||||
Luski.Snowflake Id = Luski.Snowflake.GenerateSnowflake(Tables.Channels.Read(Channels.Epoch, Channels.ID.CreateParameter(data.ChannelID)));
|
Luski.Snowflake Id = Luski.Snowflake.GenerateSnowflake(Tables.Channels.Read(Channels.Epoch, Channels.ID.CreateParameter(data.ChannelID)));
|
||||||
ChannelType type = Tables.Channels.Read(Channels.Type, Channels.ID.CreateParameter(data.ChannelID));
|
ChannelType type = Tables.Channels.Read(Channels.Type, Channels.ID.CreateParameter(data.ChannelID));
|
||||||
MessageEvent MessageEvent = new()
|
MessageEvent MessageEvent = new()
|
||||||
@ -49,7 +48,6 @@ public class SocketMessageController : ControllerBase
|
|||||||
Type = DataType.MessageCreate,
|
Type = DataType.MessageCreate,
|
||||||
Data = MessageEvent
|
Data = MessageEvent
|
||||||
}, Array.Empty<long>());
|
}, Array.Empty<long>());
|
||||||
}
|
|
||||||
Response.StatusCode = 201;
|
Response.StatusCode = 201;
|
||||||
return null!;
|
return null!;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user