Skip to content

Commit

Permalink
Fix MIME type header for importance-fraction-plot endpoint (#346)
Browse files Browse the repository at this point in the history
* Fix MIME type header for importance-fraction-plot endpoint

* version bump

---------

Co-authored-by: James Mathews <[email protected]>
  • Loading branch information
franciscouzo and jimmymathews authored Aug 9, 2024
1 parent 020bab6 commit e6482b3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion spatialprofilingtoolbox/apiserver/app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -543,4 +543,5 @@ async def importance_fraction_plot(
buffer = BytesIO()
buffer.write(raw)
buffer.seek(0)
return StreamingResponse(buffer, media_type=f"image/{img_format}")
media_type = "image/svg+xml" if img_format == "svg" else "image/png"
return StreamingResponse(buffer, media_type=media_type)
2 changes: 1 addition & 1 deletion version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.27.0
0.28.0

0 comments on commit e6482b3

Please sign in to comment.