mirror of
https://github.com/GTNewHorizons/ForestryMC.git
synced 2026-11-20 12:09:39 +00:00
Fix #1607 Wrong calculation for stamps in letters
This commit is contained in:
1 parent
56a907dbec
commit
77ecd03416
1 file changed
+3
-3
@@ -95,7 +95,7 @@ public class Letter implements ILetter {
|
||||
public int countAttachments() {
|
||||
int count = 0;
|
||||
for (ItemStack stack : getAttachments()) {
|
||||
if (stack != null) {
|
||||
if (!stack.isEmpty()) {
|
||||
count++;
|
||||
}
|
||||
}
|
||||
@@ -145,7 +145,7 @@ public class Letter implements ILetter {
|
||||
int posted = 0;
|
||||
|
||||
for (ItemStack stamp : getPostage()) {
|
||||
if (stamp == null) {
|
||||
if (stamp.isEmpty()) {
|
||||
continue;
|
||||
}
|
||||
if (!(stamp.getItem() instanceof IStamps)) {
|
||||
@@ -163,7 +163,7 @@ public class Letter implements ILetter {
|
||||
|
||||
int required = 1;
|
||||
for (ItemStack attach : getAttachments()) {
|
||||
if (attach != null) {
|
||||
if (!attach.isEmpty()) {
|
||||
required++;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user