Skip to content

Commit

Permalink
refactor: tidy codes
Browse files Browse the repository at this point in the history
Signed-off-by: Jack Cherng <[email protected]>
  • Loading branch information
jfcherng committed Mar 5, 2024
1 parent 1485259 commit 0d49775
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugin/snapshot.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,5 +116,5 @@ def get_view_pseudo_content(view: sublime.View, window: sublime.Window) -> str:
def get_view_pseudo_first_line(view: sublime.View, window: sublime.Window) -> str:
region = view.line(0)
if (max_length := get_merged_plugin_setting("trim_first_line_length", window=window)) >= 0:
region = sublime.Region(region.a, min(region.b, max_length))
region.b = min(region.b, max_length)
return view.substr(region)

0 comments on commit 0d49775

Please sign in to comment.