From f8018831b42fa9f534494babcd496f77e4709166 Mon Sep 17 00:00:00 2001 From: TrueDoctor Date: Thu, 27 Sep 2018 17:43:56 +0200 Subject: added SignalR --- DSACore/Startup.cs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'DSACore/Startup.cs') diff --git a/DSACore/Startup.cs b/DSACore/Startup.cs index 2d0c2a3..1745ea4 100644 --- a/DSACore/Startup.cs +++ b/DSACore/Startup.cs @@ -2,6 +2,7 @@ using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; +using DSACore.Hubs; using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Hosting; using Microsoft.AspNetCore.HttpsPolicy; @@ -26,6 +27,8 @@ namespace DSACore public void ConfigureServices(IServiceCollection services) { services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_2_1); + + services.AddSignalR(); } // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. @@ -41,6 +44,7 @@ namespace DSACore } app.UseHttpsRedirection(); + app.UseSignalR(routes => { routes.MapHub("/chatHub"); }); app.UseMvc(); } } -- cgit v1.2.3-54-g00ecf