We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7147b7a commit bdfc01cCopy full SHA for bdfc01c
src/client/app/composables/copyCode.ts
@@ -21,7 +21,8 @@ export function useCopyCode() {
21
sibling
22
.querySelectorAll('span.line:not(.diff.remove)')
23
.forEach((node) => (text += (node.textContent || '') + '\n'))
24
- text = text.slice(0, -1)
+
25
+ text = (text || sibling.textContent || '').slice(0, -1)
26
27
if (isShell) {
28
text = text.replace(/^ *(\$|>) /gm, '').trim()
0 commit comments