Skip to content

Commit

Permalink
null check
Browse files Browse the repository at this point in the history
  • Loading branch information
7sat committed Apr 1, 2022
1 parent 8069bfd commit ddc1706
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>me.sat7</groupId>
<artifactId>DynamicShop</artifactId>
<version>3.6.3</version>
<version>3.6.4</version>
<packaging>jar</packaging>

<name>DynamicShop</name>
Expand Down
5 changes: 5 additions & 0 deletions src/main/java/me/sat7/dynamicshop/utilities/ShopUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -929,7 +929,12 @@ public static int StockStabilizing(Boolean isLegacyMode, Random generator,int st
public static boolean CheckShopHour(String shopName, Player player)
{
CustomConfig shopData = ShopUtil.shopConfigFiles.get(shopName);
if (shopData == null)
return true;

ConfigurationSection shopConf = shopData.get().getConfigurationSection("Options");
if (shopConf == null)
return true;

if (shopConf.contains("shophours"))
{
Expand Down

0 comments on commit ddc1706

Please sign in to comment.