Closed SOF3 closed 2 years ago
sorry if it's troublesome and Thank you SOF3 :)
I don't understand what's the point of the CapitalSelector
class though. Why not jus tput it inside the capital provider class?
I've tried and the Selector is always null on construct, Is it because every time I buy an enchant, it loads a new Provider? https://github.com/MulqiGaming64/EconomyEnchant/blob/ed83bf1dedd278c62df0e0ace2575951b750b144/src/MulqiGaming64/EconomyEnchant/EconomyEnchant.php#L686
I've tried and the Selector is always null on construct, Is it because every time I buy an enchant, it loads a new Provider?
Capital::api() is not run immediately, but after Capital has verified all tables are correctly initialized. We only guarantee that it will run before your next call of Capital::api() runs.
ok maybe later i will fix it better.
I've moved it, thanks for the advice ^_^
$api->completeConfig
runs asynchronously. CallingCapitalSelector
during startup will access an uninitialized variable.I will send a pull request to fix these issues shortly.