mirror of
https://github.com/voideditor/void
synced 2026-05-23 09:28:23 +00:00
Removed unnecessary ternary in lineNumAdd
This commit is contained in:
parent
d948fc5950
commit
cbb52dec28
1 changed files with 1 additions and 1 deletions
|
|
@ -577,7 +577,7 @@ export const messageOfSelection = async (
|
|||
|
||||
if (s.type === 'CodeSelection') {
|
||||
const { val } = await readFile(opts.fileService, s.uri, DEFAULT_FILE_SIZE_LIMIT)
|
||||
const lineNumAdd = s.type === 'CodeSelection' ? lineNumAddition(s.range) : ''
|
||||
const lineNumAdd = lineNumAddition(s.range)
|
||||
const lines = val?.split('\n')
|
||||
const selection = lines?.slice(s.range[0] - 1, s.range[1]).join('\n')
|
||||
const content = selection ?? 'null'
|
||||
|
|
|
|||
Loading…
Reference in a new issue