mirror of
https://github.com/EarthMC/QuickShop-Reremake.git
synced 2026-11-24 17:39:52 -05:00
Fix a serious bug :(
Former-commit-id: 22004f9bc4fb5a8fd97fbd8ba9f3b696e4cad7fc
This commit is contained in:
1 parent
09014e83b8
commit
f22d7edc35
1 file changed
+1
-1
@@ -135,12 +135,12 @@ public class DatabaseHelper {
|
||||
}
|
||||
|
||||
public void createShop(Shop shop, Runnable onSuccess, Consumer<SQLException> onFailed) {
|
||||
plugin.getDatabaseHelper().removeShop(shop); //First purge old exist shop before create new shop.
|
||||
String sqlString = "INSERT INTO " + QuickShop.instance.getDbPrefix() + "shops (owner, price, itemConfig, x, y, z, world, unlimited, type) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)";
|
||||
plugin.getDatabaseManager().add(new DatabaseTask(sqlString, new DatabaseTask.Task() {
|
||||
@Override
|
||||
public void edit(PreparedStatement ps) throws SQLException {
|
||||
Location location = shop.getLocation();
|
||||
plugin.getDatabaseHelper().removeShop(shop); //First purge old exist shop before create new shop.
|
||||
//QuickShop.instance.getDB().execute(q, owner, price, Util.serialize(item), x, y, z, world, unlimited, shopType);
|
||||
ps.setString(1, ShopModerator.serialize(shop.getModerator()));
|
||||
ps.setDouble(2, shop.getPrice());
|
||||
|
||||
Reference in new issue
Block a user