diff --git a/unjo.Web/Startup.cs b/unjo.Web/Startup.cs index 1a23b86d..de7f8dc3 100644 --- a/unjo.Web/Startup.cs +++ b/unjo.Web/Startup.cs @@ -54,6 +54,7 @@ namespace unjo.Web // add cookie-based authentication services.AddAuthentication(CookieAuthenticationDefaults.AuthenticationScheme) .AddCookie(opts => { + // override redirect to login page (handled by vue frontend) and return a 401 instead opts.Events.OnRedirectToLogin = (context) => { context.Response.StatusCode = 401; diff --git a/unjo.Web/package.json b/unjo.Web/package.json index 45526326..374e346b 100644 --- a/unjo.Web/package.json +++ b/unjo.Web/package.json @@ -10,8 +10,7 @@ "dayjs": "^1.8.23", "lodash": "*", "vue": "^2.6.11", - "vue-router": "^3.1.6", - "vuex": "^3.1.3" + "vue-router": "^3.1.6" }, "devDependencies": { "@babel/core": "*",