mirror of
https://github.com/MilkBowl/Vault.git
synced 2024-11-14 06:36:43 +01:00
fixup createAccount for VaultEco implementation of Register
This commit is contained in:
parent
da11aa5fb1
commit
99ddfe9673
@ -34,11 +34,10 @@ public class VaultEco implements Method {
|
||||
|
||||
@Override
|
||||
public boolean createAccount(String name, Double amount) {
|
||||
if (hasAccount(name)) {
|
||||
if(!this.economy.createBank(name, "").transactionSuccess()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return false;
|
||||
return this.economy.bankDeposit(name, amount).transactionSuccess();
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
@ -77,13 +76,6 @@ public class VaultEco implements Method {
|
||||
return this.economy.createPlayerAccount(name);
|
||||
}
|
||||
|
||||
public boolean createAccount(String name, double balance) {
|
||||
if(!this.economy.createBank(name, "").transactionSuccess()) {
|
||||
return false;
|
||||
}
|
||||
return this.economy.bankDeposit(name, balance).transactionSuccess();
|
||||
}
|
||||
|
||||
public MethodAccount getAccount(String name) {
|
||||
if(!hasAccount(name))
|
||||
return null;
|
||||
|
Loading…
Reference in New Issue
Block a user