-
Bug
-
Resolution: Done
-
Minor
-
None
-
None
-
Testing environment in IntelliJ IDEA.
<dependencies> <!-- CraftBukkit API --> <dependency> <groupId>org.bukkit</groupId> <artifactId>bukkit</artifactId> <version>1.14.4-R0.1-SNAPSHOT</version> <scope>provided</scope> </dependency> </dependencies> ... <repositories> <!-- Central --> <repository> <id>central</id> <name>Central Repository</name> <url>https://repo.maven.apache.org/maven2</url> <layout>default</layout> <snapshots> <enabled>false</enabled> </snapshots> </repository> <!-- Spigot --> <repository> <id>spigot-repo</id> <url>https://hub.spigotmc.org/nexus/content/repositories/snapshots/</url> <snapshots> <enabled>true</enabled> <updatePolicy>always</updatePolicy> <checksumPolicy>fail</checksumPolicy> </snapshots> </repository> <!-- Vault --> <repository> <id>jitpack.io</id> <url>https://jitpack.io</url> </repository> </repositories>
Testing environment in IntelliJ IDEA. <dependencies> <!-- CraftBukkit API --> <dependency> <groupId> org.bukkit </groupId> <artifactId> bukkit </artifactId> <version> 1.14.4-R0.1-SNAPSHOT </version> <scope> provided </scope> </dependency> </dependencies> ... <repositories> <!-- Central --> <repository> <id> central </id> <name> Central Repository </name> <url> https://repo.maven.apache.org/maven2 </url> <layout> default </layout> <snapshots> <enabled> false </enabled> </snapshots> </repository> <!-- Spigot --> <repository> <id> spigot-repo </id> <url> https://hub.spigotmc.org/nexus/content/repositories/snapshots/ </url> <snapshots> <enabled> true </enabled> <updatePolicy> always </updatePolicy> <checksumPolicy> fail </checksumPolicy> </snapshots> </repository> <!-- Vault --> <repository> <id> jitpack.io </id> <url> https://jitpack.io </url> </repository> </repositories>
-
1.14.4-R0.1-SNAPSHOT-20190826.092815-45
-
Yes
Running this snippet:
ItemStack itemStack = new ItemStack(Material.DIAMOND, 1); System.out.println(itemStack.toString());
Gives this error:
java.lang.NullPointerExceptionjava.lang.NullPointerException at org.bukkit.Bukkit.getItemFactory(Bukkit.java:1121) at org.bukkit.inventory.ItemStack.hasItemMeta(ItemStack.java:540) at org.bukkit.inventory.ItemStack.toString(ItemStack.java:236) at com.github.gjvnq.BidCraft.Model.OrderTest.execute(MyCode.java:21)