Restore some SANITY around nullability annotations
Some of these were wrong (scoreboard manager), others are counter to everything everyone expects (Locations world being null, which wasnt ever safe EVER) others are just too noisy. Replace some with Contract to get rid of the nullability constraint and go back to the old days of IDE not considering it strictly one way or the other. Also, stop requiring annotations on package-private. Introduces the next Developer Perk for Paper-API: Your plugin isn't yellow anymore. Also fixed random dupe code in ensureServerConversions that got mistakenly set in the update.
This commit is contained in:
parent
b1777724a5
commit
4ae1989c4f
6 changed files with 166 additions and 18 deletions
|
@ -1,4 +1,4 @@
|
|||
From c2814c3f3d70e2834f47c4bb3beafb0d591d4985 Mon Sep 17 00:00:00 2001
|
||||
From 35bbd72e452d3c31afe5217706a2a60df856117f Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Wed, 4 May 2016 23:55:48 -0400
|
||||
Subject: [PATCH] Add getI18NDisplayName API
|
||||
|
@ -29,10 +29,10 @@ index 8e602cf51..dca77bbaf 100644
|
|||
// Paper end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/inventory/ItemStack.java b/src/main/java/org/bukkit/inventory/ItemStack.java
|
||||
index e8f97c949..b1c02ac0d 100644
|
||||
index 4ee01be5f..3ff3458e7 100644
|
||||
--- a/src/main/java/org/bukkit/inventory/ItemStack.java
|
||||
+++ b/src/main/java/org/bukkit/inventory/ItemStack.java
|
||||
@@ -595,5 +595,17 @@ public class ItemStack implements Cloneable, ConfigurationSerializable {
|
||||
@@ -590,5 +590,17 @@ public class ItemStack implements Cloneable, ConfigurationSerializable {
|
||||
public ItemStack ensureServerConversions() {
|
||||
return Bukkit.getServer().getItemFactory().ensureServerConversions(this);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue