-
-
Notifications
You must be signed in to change notification settings - Fork 356
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Alter Account & Transaction and fix TownyTransactionEvent. (#7431)
* Fix the TownyTransactionEvent assuming a player is involved. Alters Transactions to no longer use a Player and instead try to use a TownyObject. Rethink Transaction to adopt a Account instead of a TownyObject and Name. Fix javadoc Fix Account initializing TownyObject null. Add helper method to Transaction. Clean up EconomyAccount, move the TownyServerAccount instance to Account. Alter Transaction again in order to add both Receiving and Sending accounts. Remove getName/getTownyObject from Transaction, change TownyObject in Account over to EconomyHandler. Return government field to BankAccount. Throw the TownyTransactionEvent earlier, so that we can better support the new sender and receiver fields in the Transaction. Fix flipped sender/receiver. Notify observers of payTo/payFromServer only when the transaction is a success. A very hacky way to get the TownyServerAccount to implement EconomyHandler. Change transaction package, adopt new builder pattern, deprecate existing Transaction and TransactionType classes. Reduce diff and a couple better javadocs * Rebased and accounted for recent changes in TownyAdminCommand, also add annotations and helper methods to Transaction. * Update deprecated in version number. * Change Transaction#getPlayer to address review.
- Loading branch information
Showing
28 changed files
with
331 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
Towny/src/main/java/com/palmergames/bukkit/towny/event/economy/NationTransactionEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
Towny/src/main/java/com/palmergames/bukkit/towny/event/economy/TownTransactionEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
Towny/src/main/java/com/palmergames/bukkit/towny/event/economy/TownyTransactionEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 5 additions & 0 deletions
5
Towny/src/main/java/com/palmergames/bukkit/towny/object/TransactionType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.