Skip to content

Commit

Permalink
Locations: Sort by name
Browse files Browse the repository at this point in the history
  • Loading branch information
dbrgn committed Mar 13, 2024
1 parent 72d5144 commit 7284241
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frontend/src/routes/locations/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export async function loadApiLocations(fetch: SvelteKitFetch): Promise<Location[
switch (res.status) {
case 200: {
const response = SCHEMA_API_LOCATIONS_RESPONSE.parse(await res.json());
return response.locations;
return response.locations.sort((a, b) => a.name.localeCompare(b.name));
}
case 401:
throw AuthenticationError.redirectToLogin(`/locations/`);
Expand Down

0 comments on commit 7284241

Please sign in to comment.