Skip to content

Commit fac33dd

Browse files
committed
Update unlink
Signed-off-by: Alex Ivanov <ai@contributor.pw>
1 parent 62ff0a8 commit fac33dd

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

snippets/sheets/unlink_urls/index.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,8 @@ function unlinkUrls_(range = SpreadsheetApp.getActiveRange()) {
88
return range.setRichTextValues(
99
range.getRichTextValues().map((rowRichTextValues) =>
1010
rowRichTextValues.map((richTextValue) => {
11-
let copy;
1211
if (richTextValue.getRuns().some((ruin) => ruin.getLinkUrl())) {
13-
copy = richTextValue.copy();
12+
const copy = richTextValue.copy();
1413
copy.setLinkUrl(undefined);
1514
return copy.build();
1615
}

0 commit comments

Comments
 (0)