From fd7b45a8c78756157a4d80a133e794ec7775b528 Mon Sep 17 00:00:00 2001 From: Christina Date: Fri, 8 Nov 2024 22:23:11 +0100 Subject: [PATCH 1/2] use the correct data-sort-key for unacknowledged messages --- views/channels.ecr | 2 +- views/connection.ecr | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/views/channels.ecr b/views/channels.ecr index 592c838cb..6223b2180 100644 --- a/views/channels.ecr +++ b/views/channels.ecr @@ -20,7 +20,7 @@ Mode Consumers Prefetch limit - Unacked messages + Unacked messages diff --git a/views/connection.ecr b/views/connection.ecr index 1dcf1ed3f..d006a3b0b 100644 --- a/views/connection.ecr +++ b/views/connection.ecr @@ -86,7 +86,7 @@ Mode Consumers Prefetch limit - Unacked messages + Unacked messages From 481c69e3c8ee248ce2c11b35e039f86c33f8cf96 Mon Sep 17 00:00:00 2001 From: Christina Date: Fri, 8 Nov 2024 23:27:40 +0100 Subject: [PATCH 2/2] allow controller to sort on uint16 types --- src/lavinmq/http/controller.cr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lavinmq/http/controller.cr b/src/lavinmq/http/controller.cr index 798262cdc..f3559a843 100644 --- a/src/lavinmq/http/controller.cr +++ b/src/lavinmq/http/controller.cr @@ -55,7 +55,7 @@ module LavinMQ if first_element = sorted_items.first? {% begin %} case dig(first_element, sort_by) - {% for k in {Int32, UInt32, UInt64, Float64} %} + {% for k in {Int32, UInt16, UInt32, UInt64, Float64} %} when {{k.id}} sorted_items.sort_by! { |i| dig(i, sort_by).as({{k.id}}) } {% end %}