Don't crash the server when duplicate block at position

This commit is contained in:
zontreck 2024-04-24 23:53:43 -07:00
parent ab6f9130f0
commit 995e78dec8
2 changed files with 4 additions and 5 deletions

View file

@ -53,7 +53,7 @@ mod_name=Zontreck's Library Mod
# The license of the mod. Review your options at https://choosealicense.com/. All Rights Reserved is the default. # The license of the mod. Review your options at https://choosealicense.com/. All Rights Reserved is the default.
mod_license=GPLv3 mod_license=GPLv3
# The mod version. See https://semver.org/ # The mod version. See https://semver.org/
mod_version=1201.13.042424.0415 mod_version=1201.13.042424.2353
# The group ID for the mod. It is only important when publishing as an artifact to a Maven repository. # The group ID for the mod. It is only important when publishing as an artifact to a Maven repository.
# This should match the base package used for the mod sources. # This should match the base package used for the mod sources.
# See https://maven.apache.org/guides/mini/guide-naming-conventions.html # See https://maven.apache.org/guides/mini/guide-naming-conventions.html

View file

@ -96,10 +96,9 @@ public abstract class BlockRestoreQueue
DatabaseWrapper.get().executePreparedStatement(pstmt); DatabaseWrapper.get().executePreparedStatement(pstmt);
} catch (SQLException e) { } catch (Exception e)
throw new RuntimeException(e); {
} catch (IOException e) { // Duplicate block insertion, we only cache each block one time by default. If this function is overridden to use a different table, perhaps multiple blocks for the same position could be cached.
throw new RuntimeException(e);
} }
} }