Skip to content

Commit

Permalink
🚑 修复商品图标显示 (#1823)
Browse files Browse the repository at this point in the history
  • Loading branch information
HibiKier authored Jan 7, 2025
1 parent 2c798a6 commit e124c1d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions zhenxun/builtin_plugins/shop/html_image.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,10 @@ async def html_image() -> bytes:
if goods[1].icon:
path = ICON_PATH / goods[1].icon
if path.exists():
icon = "data:image/png;base64,"
f"{BuildImage.open(ICON_PATH / goods[1].icon).pic2bs4()[9:]}"
icon = (
"data:image/png;base64,"
f"{BuildImage.open(ICON_PATH / goods[1].icon).pic2bs4()[9:]}"
)
partition_dict[goods[1].partition].append(
{
"id": goods[0],
Expand Down

0 comments on commit e124c1d

Please sign in to comment.