Skip to content

Commit

Permalink
fixed malformed name and price variables
Browse files Browse the repository at this point in the history
  • Loading branch information
BlvckBytes committed Oct 28, 2024
1 parent 9a3f7c2 commit c7703e4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ public CachedShop(

this.shopEnvironment = new EvaluationEnvironmentBuilder()
.withLiveVariable("owner", handle.getOwner()::getDisplay)
.withLiveVariable("name", () -> shopManager.format(handle.getPrice(), handle))
.withLiveVariable("price", handle::getPrice)
.withLiveVariable("name", handle::getShopName)
.withLiveVariable("price", () -> shopManager.format(handle.getPrice(), handle))
.withLiveVariable("item_type", () -> formatItemType(handle.getItem()))
.withLiveVariable("remaining_stock", () -> this.cachedStock)
.withLiveVariable("remaining_space", () -> this.cachedSpace)
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/resources/config/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ resultDisplay:
- '@{ANY-CONTROL-LORE-SPACER}'
- '@{REPRESENTATIVE-LORE-OWNER}'
- 'if name != null then @{REPRESENTATIVE-LORE-NAME} else null'
- '@{REPRESENTATIVE-LORE-PRICE(currency=currency ?? "")}'
- '@{REPRESENTATIVE-LORE-PRICE}'
- |
if is_buying then
@{REPRESENTATIVE-LORE-REMAINING-SPACE(remaining_space=if is_unlimited then "∞" else remaining_space)}
Expand Down

0 comments on commit c7703e4

Please sign in to comment.