- Timestamp:
- Feb 26, 2024, 6:25:48 PM (9 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TFP-WebServer/WebServer/src/WebAPI/APIs/Permissions/CommandPermissions.cs
r434 r486 58 58 59 59 if (string.IsNullOrEmpty (id)) { 60 SendEmptyResponse (_context, HttpStatusCode.BadRequest, _jsonInputData, "NO_COMMAND");60 SendEmptyResponse (_context, HttpStatusCode.BadRequest, _jsonInputData, EApiErrorCode.NO_COMMAND); 61 61 return; 62 62 } … … 64 64 IConsoleCommand cmd = SdtdConsole.Instance.GetCommand (id); 65 65 if (cmd == null) { 66 SendEmptyResponse (_context, HttpStatusCode.NotFound, _jsonInputData, "INVALID_COMMAND");66 SendEmptyResponse (_context, HttpStatusCode.NotFound, _jsonInputData, EApiErrorCode.UNKNOWN_COMMAND); 67 67 return; 68 68 } 69 69 70 70 if (!JsonCommons.TryGetJsonField (_jsonInput, propertyPermissionLevel, out int permissionLevel)) { 71 SendEmptyResponse (_context, HttpStatusCode.BadRequest, _jsonInputData, "NO_OR_INVALID_PERMISSION_LEVEL");71 SendEmptyResponse (_context, HttpStatusCode.BadRequest, _jsonInputData, EApiErrorCode.NO_OR_INVALID_PERMISSION_LEVEL); 72 72 return; 73 73 }
Note:
See TracChangeset
for help on using the changeset viewer.