Ignore:
Timestamp:
Aug 6, 2022, 11:32:32 PM (2 years ago)
Author:
alloc
Message:

Big refactoring in Web to pass around a Context instead of a bunch of individual arguments all the time

File:
1 edited

Legend:

Unmodified
Added
Removed
  • binary-improvements2/MapRendering/Web/API/GetWebMods.cs

    r384 r387  
    11using AllocsFixes.JSON;
    2 using HttpListenerRequest = SpaceWizards.HttpListener.HttpListenerRequest;
    3 using HttpListenerResponse = SpaceWizards.HttpListener.HttpListenerResponse;
    42
    53namespace AllocsFixes.NetConnections.Servers.Web.API {
    6         public class GetWebMods : WebAPI {
     4        public class GetWebMods : AbsWebAPI {
    75                private readonly JSONArray loadedWebMods = new JSONArray ();
    86
     
    2725                }
    2826
    29                 public override void HandleRequest (HttpListenerRequest _req, HttpListenerResponse _resp, WebConnection _user,
    30                         int _permissionLevel) {
    31 
    32                         WriteJSON (_resp, loadedWebMods);
     27                public override void HandleRequest (RequestContext _context) {
     28                        WebUtils.WriteJson (_context.Response, loadedWebMods);
    3329                }
    3430
Note: See TracChangeset for help on using the changeset viewer.