more changes

This commit is contained in:
boy0001 2015-02-19 17:08:15 +11:00
parent f154754e1b
commit d227bcc739
27 changed files with 1151 additions and 351 deletions

View file

@ -32,6 +32,8 @@ import java.util.logging.Level;
import org.bukkit.plugin.Plugin;
import com.intellectualcrafters.plot.PlotSquared;
/**
* Connects to and uses a SQLite database
*
@ -49,8 +51,8 @@ public class SQLite extends Database {
* @param plugin Plugin instance
* @param dbLocation Location of the Database (Must end in .db)
*/
public SQLite(final Plugin plugin, final String dbLocation) {
super(plugin);
public SQLite(final PlotSquared plotsquared, final String dbLocation) {
super(plotsquared);
this.dbLocation = dbLocation;
}
@ -59,7 +61,7 @@ public class SQLite extends Database {
if (checkConnection()) {
return this.connection;
}
if (!this.plugin.getDataFolder().exists()) {
if (!this.plotsquared.IMP.getDirectory().exists()) {
this.plugin.getDataFolder().mkdirs();
}
final File file = new File(this.dbLocation);