mirror of
https://github.com/GeorgH93/Minepacks.git
synced 2024-11-14 10:45:23 +01:00
Cleanup resources
This commit is contained in:
parent
520c54c909
commit
eabff6dc2e
@ -61,9 +61,9 @@ public SQL(MinePacks mp)
|
|||||||
// Delete old backpacks
|
// Delete old backpacks
|
||||||
if(maxAge > 0)
|
if(maxAge > 0)
|
||||||
{
|
{
|
||||||
try
|
try(Connection connection = getConnection(); Statement statement = connection.createStatement())
|
||||||
{
|
{
|
||||||
getConnection().createStatement().execute(queryDeleteOldBackpacks);
|
statement.execute(queryDeleteOldBackpacks);
|
||||||
}
|
}
|
||||||
catch(SQLException e)
|
catch(SQLException e)
|
||||||
{
|
{
|
||||||
@ -409,4 +409,4 @@ public Backpack loadBackpack(OfflinePlayer player) // The sync function shouldn'
|
|||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user