File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -516,7 +516,7 @@ local create_autocommands = function(
516516 imply_local ,
517517 opts
518518)
519- local last_line , last_suggestion = suggestions [1 ].note_start_linenr , suggestions [ 1 ]
519+ local last_line = suggestions [1 ].note_start_linenr
520520
521521 --- Update the suggestion buffer if the selected suggestion changes in the Comment buffer.
522522 local update_suggestion_buffer = function ()
@@ -527,16 +527,11 @@ local create_autocommands = function(
527527 local suggestion = List .new (suggestions ):find (function (sug )
528528 return current_line <= sug .note_end_linenr
529529 end )
530- local old_buffer_text = u .get_buffer_text (suggestion_buf )
531- if
532- not suggestion
533- or suggestion == last_suggestion
534- or old_buffer_text == table.concat (suggestion .full_text , " \n " )
535- then
530+ if not suggestion or u .get_buffer_text (suggestion_buf ) == table.concat (suggestion .full_text , " \n " ) then
536531 return
537532 end
538533 set_buffer_lines (suggestion_buf , suggestion .full_text , imply_local )
539- last_line , last_suggestion = current_line , suggestion
534+ last_line = current_line
540535 refresh_signs (suggestion , note_buf )
541536 end
542537
You can’t perform that action at this time.
0 commit comments