1
0
mirror of https://github.com/bitwarden/server.git synced 2025-06-30 15:42:48 -05:00

fix warnings

This commit is contained in:
Kyle Spearrin
2020-01-10 08:47:58 -05:00
parent 29580684a3
commit 7fd6e4359d
12 changed files with 28 additions and 20 deletions

View File

@ -9,6 +9,7 @@ using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using Microsoft.IdentityModel.Tokens;
using Stripe;
using Microsoft.Extensions.Hosting;
namespace Bit.Api.Utilities
{
@ -113,7 +114,7 @@ namespace Bit.Api.Utilities
else
{
var errorModel = internalErrorModel ?? new InternalApi.ErrorResponseModel(errorMessage);
var env = context.HttpContext.RequestServices.GetRequiredService<IHostingEnvironment>();
var env = context.HttpContext.RequestServices.GetRequiredService<IWebHostEnvironment>();
if(env.IsDevelopment())
{
errorModel.ExceptionMessage = exception.Message;