From 4837a77b3280ec50d9b175d851dd8ebc8e8a048a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=87=8E=E5=A3=B0?= Date: Mon, 8 Apr 2024 16:29:48 +0800 Subject: [PATCH] Use pairs to iter both table and array (#6) --- lib/util.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/util.lua b/lib/util.lua index 42998b3..0c09de2 100644 --- a/lib/util.lua +++ b/lib/util.lua @@ -62,7 +62,7 @@ end function UTIL.calculate_shorthand(list) local versions_shorthand = {} - for _, v in ipairs(list) do + for _, v in pairs(list) do local version = v.version local major, minor = UTIL.extract_semver(version)