Skip to content

Commit

Permalink
refactor(scancode)!: Make parseScanResult(JsonElement) private
Browse files Browse the repository at this point in the history
It is sufficent to expose `parseScanResult(String)` to the public.

Signed-off-by: Frank Viernau <[email protected]>
  • Loading branch information
fviernau committed Dec 1, 2023
1 parent da463b8 commit 247b046
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ fun parseResult(result: File) = parseResult(result.readText())

fun parseResult(result: String) = parseResult(Json.parseToJsonElement(result))

fun parseResult(result: JsonElement): ScanCodeResult {
private fun parseResult(result: JsonElement): ScanCodeResult {
// As even the structure of the header itself may change with the output format version, first operate on raw JSON
// elements to get the version, and then parse the JSON elements into the appropriate data classes.
val header = result.jsonObject.getValue("headers").jsonArray.single().jsonObject
Expand Down

0 comments on commit 247b046

Please sign in to comment.