mirror of
				https://github.com/neovim/neovim.git
				synced 2025-11-04 01:34:25 +00:00 
			
		
		
		
	Bugfix for floating_preview
Don't modify your inputs.
This commit is contained in:
		@@ -262,6 +262,9 @@ function M.open_floating_preview(contents, filetype, opts)
 | 
			
		||||
    opts = { opts, 't', true };
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  -- Don't modify our inputs.
 | 
			
		||||
  contents = vim.deepcopy(contents)
 | 
			
		||||
 | 
			
		||||
  -- Trim empty lines from the end.
 | 
			
		||||
  for i = #contents, 1, -1 do
 | 
			
		||||
    if #contents[i] == 0 then
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user