Skip to content

Commit 10b3276

Browse files
committed
Fix that language is not passed to Highlightr
1 parent 38b8f2a commit 10b3276

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Core/Sources/SuggestionWidget/SuggestionWidgetController.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,7 @@ func highlighted(code: String, language: String) -> [NSAttributedString] {
389389
}
390390
highlighter.setTheme(to: "atom-one-dark")
391391
highlighter.theme.setCodeFont(.monospacedSystemFont(ofSize: 13, weight: .regular))
392-
guard let formatted = highlighter.highlight(code, as: "swift") else {
392+
guard let formatted = highlighter.highlight(code, as: language) else {
393393
return convertToCodeLines(NSAttributedString(string: code))
394394
}
395395
return convertToCodeLines(formatted)

0 commit comments

Comments
 (0)