Skip to content

/pay uses wrong currency format (decimals) #2355

@robinstiege

Description

@robinstiege

Information

Full output of /ess version:

[15:30:20 INFO]: Server Version: 1.12.2-R0.1-SNAPSHOT git-Spigot-dcd1643-e60fc34 (MC: 1.12.2)
[15:30:20 INFO]: EssentialsX Version: 2.16.0.6
[15:30:20 INFO]: LuckPerms Version: 4.3.17
[15:30:20 INFO]: Vault Version: 1.7.1-b91
[15:30:20 INFO]: EssentialsXSpawn Version: 2.16.0.6

EssentialsX config: https://gist.github.com/StiegeRobin/71f4c04d9df8aa123d96a4bc79538ca3

Details

Description
The command /pay doesn't take care of the currency-symbol-format-locale setting. When a player want to pay 50 cents seperated with a comma (like it's also displayed with /money), they will pay 50 euro instead.

Steps to reproduce

  1. Change the currency-symbol-format-locale to de-DE
  2. Change the minimum-pay-amount to at least 0.01
  3. Do /ess reload
  4. Pay someone a german formatted amount of money like /pay User 100,50 (these are 100 euro and 50 cents)
  5. You will see that you've paid 1.005,00 to that User instead of 100,50.

Expected behavior
As I've changed the currency format to german, the /pay command should also utilize it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: open to PRLow priority enhancements that anyone is welcome to contribute.type: problemProblems that are not strictly bugs.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions