Skip to content

Commit 80a160b

Browse files
committed
fix: need to convert UTF encoding of CSP stream before JSON input
1 parent 9320089 commit 80a160b

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [2.8.0] - Unreleased
9+
10+
### Fixed
11+
- Fixed improper encoding of unicode characters in commit messages (#627)
12+
813
## [2.7.0] - 2024-11-04
914

1015
### Added

cls/SourceControl/Git/WebUIDriver.cls

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,12 @@ ClassMethod HandleRequest(pagePath As %String, InternalName As %String = "", Out
244244
}
245245
set handled = 1
246246
} elseif (pathStart = "git-command") {
247-
set requestBody = ##class(%Library.DynamicObject).%FromJSON(%request.Content)
247+
set stringBody = ""
248+
while '%request.Content.AtEnd {
249+
set stringBody = stringBody _ %request.Content.Read()
250+
}
251+
set stringBody = $zconvert(stringBody,"I","UTF8")
252+
set requestBody = ##class(%Library.DynamicObject).%FromJSON(stringBody)
248253
set command = requestBody.command
249254

250255
set gitCmd = command.%Get(0)

0 commit comments

Comments
 (0)