Skip to content

Commit

Permalink
Merge pull request #118 from JohnStrunk/nowrap
Browse files Browse the repository at this point in the history
Return the summary as a single line in the API
  • Loading branch information
mergify[bot] authored Jun 13, 2024
2 parents e161916 + 54a65a0 commit 6d5c64b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion summarize_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,11 @@ def summarize_issue():
issue_cache.remove_older_than(when)

issue = issue_cache.get_issue(client, key)
summary = summarizer.summarize_issue(issue, max_depth=1)
return {
"key": key,
"summary": summarizer.summarize_issue(issue, max_depth=1),
# Convert the summary into a single line, removing newlines and extra spaces
"summary": " ".join(summary.split()),
"user": get_jwt_identity(),
}

Expand Down

0 comments on commit 6d5c64b

Please sign in to comment.