diff --git a/TaikoWebUI/Pages/Users.razor b/TaikoWebUI/Pages/Users.razor index 006948c..ac087c7 100644 --- a/TaikoWebUI/Pages/Users.razor +++ b/TaikoWebUI/Pages/Users.razor @@ -29,7 +29,7 @@ @if (isLoading || response == null) { // Loading... - for (uint i = 0; i < currentPageSize; i++) { + for (uint i = 0; i < pageSize; i++) { diff --git a/TaikoWebUI/Pages/Users.razor.cs b/TaikoWebUI/Pages/Users.razor.cs index 644066d..c6729f8 100644 --- a/TaikoWebUI/Pages/Users.razor.cs +++ b/TaikoWebUI/Pages/Users.razor.cs @@ -7,13 +7,13 @@ public partial class Users private int TotalPages { get; set; } = 0; private bool isLoading = true; private int currentPage = 1; - private int currentPageSize = 12; + private readonly int pageSize = 12; private string? searchTerm = null; private async Task GetUsersData() { isLoading = true; - response = await Client.GetFromJsonAsync($"api/Users?page={currentPage}&limit={currentPageSize}&searchTerm={searchTerm}"); + response = await Client.GetFromJsonAsync($"api/Users?page={currentPage}&limit={pageSize}&searchTerm={searchTerm}"); response.ThrowIfNull(); TotalPages = response.TotalPages;