Closed zefir-git closed 7 months ago
POS command (all commands are executed async) cannot access chest from async context as Bukkit world data can only be accessed from the main thread.
This PR add a method to run code on the main thread and return the result back to the async thread. https://github.com/cloudnode-pro/BankAccounts/blob/76cd84eba2ec33d71e7c8b7191785a8f6291778c/src/main/java/pro/cloudnode/smp/bankaccounts/BankAccounts.java#L389-L405
[!WARNING] The async thread is blocked until the main thread code is executed and data is returned.
POS command (all commands are executed async) cannot access chest from async context as Bukkit world data can only be accessed from the main thread.
This PR add a method to run code on the main thread and return the result back to the async thread. https://github.com/cloudnode-pro/BankAccounts/blob/76cd84eba2ec33d71e7c8b7191785a8f6291778c/src/main/java/pro/cloudnode/smp/bankaccounts/BankAccounts.java#L389-L405