mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
Dispatcher: Fix subtle bug with modified items being added twice to the sort index (#9628)
Discovered by @poire-z in https://github.com/koreader/koreader/pull/9531#issuecomment-1274839234
This commit is contained in:
@@ -518,7 +518,9 @@ function Dispatcher:_addToOrder(location, settings, item)
|
||||
end
|
||||
end
|
||||
else
|
||||
table.insert(location[settings].settings.order, item)
|
||||
if not util.arrayContains(location[settings].settings.order, item) then
|
||||
table.insert(location[settings].settings.order, item)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user