diff --git a/app/assets/javascripts/admin/addon/components/dashboard-problems.gjs b/app/assets/javascripts/admin/addon/components/dashboard-problems.gjs index 61cb594303c..b1bd75f70c2 100644 --- a/app/assets/javascripts/admin/addon/components/dashboard-problems.gjs +++ b/app/assets/javascripts/admin/addon/components/dashboard-problems.gjs @@ -1,6 +1,7 @@ import Component from "@glimmer/component"; import { concat } from "@ember/helper"; import { action } from "@ember/object"; +import { compare } from "@ember/utils"; import { eq } from "truth-helpers"; import ConditionalLoadingSection from "discourse/components/conditional-loading-section"; import DButton from "discourse/components/d-button"; @@ -23,7 +24,7 @@ export default class DashboardProblems extends Component { } get problems() { - return this.args.problems.sortBy("priority"); + return this.args.problems.sort((a, b) => compare(a?.priority, b?.priority)); }