Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ClipboardTools has error #295

Open
sky9900 opened this issue Apr 11, 2023 · 1 comment
Open

ClipboardTools has error #295

sky9900 opened this issue Apr 11, 2023 · 1 comment

Comments

@sky9900
Copy link

sky9900 commented Apr 11, 2023

image

@jacix
Copy link
Contributor

jacix commented Jul 18, 2024

This appears to be fixed. The current version of that block of text is:

-- Internal method: deduplicate the given list, and restrict it to the history size limit
function obj:dedupe_and_resize(list)
   local res={}
   local hashes={}
   for i,v in ipairs(list) do
      if #res < self.hist_size then
         local hash=hashfn(v.content)
         if (not self.deduplicate) or (not hashes[hash]) then
            table.insert(res, v)
            hashes[hash]=true
         end 
      end
   end
   return res
end

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants