From 2dfac53feee2fe49fa1748d699a28f02c1cf04af Mon Sep 17 00:00:00 2001 From: Robert Dailey Date: Sat, 19 Jun 2021 13:05:01 -0500 Subject: [PATCH] fixup! Add initial Blazor Server project --- src/Recyclarr/Pages/Error.cshtml | 42 ------------------- src/Recyclarr/Pages/Error.cshtml.cs | 28 ------------- .../Radarr/CustomFormats/CustomFormats.razor | 1 - .../SelectCustomFormatsModal.razor | 1 - .../Pages/Radarr/QualityProfiles.razor | 2 +- src/Recyclarr/Pages/_Host.cshtml | 2 +- 6 files changed, 2 insertions(+), 74 deletions(-) delete mode 100644 src/Recyclarr/Pages/Error.cshtml delete mode 100644 src/Recyclarr/Pages/Error.cshtml.cs diff --git a/src/Recyclarr/Pages/Error.cshtml b/src/Recyclarr/Pages/Error.cshtml deleted file mode 100644 index d92a0d1d..00000000 --- a/src/Recyclarr/Pages/Error.cshtml +++ /dev/null @@ -1,42 +0,0 @@ -@page -@model Recyclarr.Pages.ErrorModel - - - - - - - - Error - - - - - -
-
-

Error.

-

An error occurred while processing your request.

- - @if (Model.ShowRequestId) - { -

- Request ID: @Model.RequestId -

- } - -

Development Mode

-

- Swapping to the Development environment displays detailed information about the error that occurred. -

-

- The Development environment shouldn't be enabled for deployed applications. - It can result in displaying sensitive information from exceptions to end users. - For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT environment variable to Development - and restarting the app. -

-
-
- - - diff --git a/src/Recyclarr/Pages/Error.cshtml.cs b/src/Recyclarr/Pages/Error.cshtml.cs deleted file mode 100644 index 17fafaad..00000000 --- a/src/Recyclarr/Pages/Error.cshtml.cs +++ /dev/null @@ -1,28 +0,0 @@ -using System.Diagnostics; -using Microsoft.AspNetCore.Mvc; -using Microsoft.AspNetCore.Mvc.RazorPages; -using Microsoft.Extensions.Logging; - -namespace Recyclarr.Pages -{ - [ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)] - [IgnoreAntiforgeryToken] - public class ErrorModel : PageModel - { - private readonly ILogger _logger; - - public ErrorModel(ILogger logger) - { - _logger = logger; - } - - public string? RequestId { get; set; } - - public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); - - public void OnGet() - { - RequestId = Activity.Current?.Id ?? HttpContext.TraceIdentifier; - } - } -} diff --git a/src/Recyclarr/Pages/Radarr/CustomFormats/CustomFormats.razor b/src/Recyclarr/Pages/Radarr/CustomFormats/CustomFormats.razor index 932647e3..7d4e66f5 100644 --- a/src/Recyclarr/Pages/Radarr/CustomFormats/CustomFormats.razor +++ b/src/Recyclarr/Pages/Radarr/CustomFormats/CustomFormats.razor @@ -1,5 +1,4 @@ @page "/radarr/custom-formats" -@using MudBlazor @layout CustomFormatAccessLayout
diff --git a/src/Recyclarr/Pages/Radarr/CustomFormats/SelectCustomFormatsModal.razor b/src/Recyclarr/Pages/Radarr/CustomFormats/SelectCustomFormatsModal.razor index 34f3d4c6..0daf90d2 100644 --- a/src/Recyclarr/Pages/Radarr/CustomFormats/SelectCustomFormatsModal.razor +++ b/src/Recyclarr/Pages/Radarr/CustomFormats/SelectCustomFormatsModal.razor @@ -1,4 +1,3 @@ -@using MudBlazor @{ #nullable disable } diff --git a/src/Recyclarr/Pages/Radarr/QualityProfiles.razor b/src/Recyclarr/Pages/Radarr/QualityProfiles.razor index 86718553..8341e7c5 100644 --- a/src/Recyclarr/Pages/Radarr/QualityProfiles.razor +++ b/src/Recyclarr/Pages/Radarr/QualityProfiles.razor @@ -8,7 +8,7 @@ @code { [Inject] - public IQualityProfileService ProfileService { get; set; } + public IQualityProfileService ProfileService { get; set; } = default!; protected override async Task OnInitializedAsync() { diff --git a/src/Recyclarr/Pages/_Host.cshtml b/src/Recyclarr/Pages/_Host.cshtml index 5660035e..08b89a06 100644 --- a/src/Recyclarr/Pages/_Host.cshtml +++ b/src/Recyclarr/Pages/_Host.cshtml @@ -29,7 +29,7 @@ @* *@ - + @* *@