1
0
mirror of https://github.com/lucko/LuckPerms.git synced 2025-09-25 13:28:58 +02:00

Fix compile and some minor formatting errors

This commit is contained in:
Luck
2018-02-20 20:15:48 +00:00
parent 9c92522564
commit da9977a30f
6 changed files with 11 additions and 11 deletions

View File

@@ -328,7 +328,7 @@ data:
# The prefix to use for all LuckPerms collections. Change this if you want to use different # The prefix to use for all LuckPerms collections. Change this if you want to use different
# collections for different servers. The default is no prefix. # collections for different servers. The default is no prefix.
mongodb_collection_prefix: '' mongodb_collection_prefix: ''
# MongoDB ClientConnectionURI for use with replicasets and custom connection options # MongoDB ClientConnectionURI for use with replicasets and custom connection options
# See https://docs.mongodb.com/manual/reference/connection-string/ # See https://docs.mongodb.com/manual/reference/connection-string/
mongodb_connection_URI: '' mongodb_connection_URI: ''

View File

@@ -270,7 +270,7 @@ data:
# The prefix to use for all LuckPerms collections. Change this if you want to use different # The prefix to use for all LuckPerms collections. Change this if you want to use different
# collections for different servers. The default is no prefix. # collections for different servers. The default is no prefix.
mongodb_collection_prefix: '' mongodb_collection_prefix: ''
# MongoDB ClientConnectionURI for use with replicasets and custom connection options # MongoDB ClientConnectionURI for use with replicasets and custom connection options
# See https://docs.mongodb.com/manual/reference/connection-string/ # See https://docs.mongodb.com/manual/reference/connection-string/
mongodb_connection_URI: '' mongodb_connection_URI: ''

View File

@@ -404,12 +404,12 @@ public class ConfigKeys {
* The prefix for any MongoDB collections * The prefix for any MongoDB collections
*/ */
public static final ConfigKey<String> MONGODB_COLLECTION_PREFIX = EnduringKey.wrap(StringKey.of("data.mongodb_collection_prefix", "")); public static final ConfigKey<String> MONGODB_COLLECTION_PREFIX = EnduringKey.wrap(StringKey.of("data.mongodb_collection_prefix", ""));
/** /**
* MongoDB ClientConnectionURI to override default connection options * MongoDB ClientConnectionURI to override default connection options
*/ */
public static final ConfigKey<String> MONGODB_CONNECTION_URI = EnduringKey.wrap(StringKey.of("data.mongodb_connection_URI", "")); public static final ConfigKey<String> MONGODB_CONNECTION_URI = EnduringKey.wrap(StringKey.of("data.mongodb_connection_URI", ""));
/** /**
* The name of the storage method being used * The name of the storage method being used
*/ */

View File

@@ -78,19 +78,19 @@ public class MongoDao extends AbstractDao {
private MongoClient mongoClient; private MongoClient mongoClient;
private MongoDatabase database; private MongoDatabase database;
private final String prefix; private final String prefix;
private final String connectionURI; private final String connectionUri;
public MongoDao(LuckPermsPlugin plugin, StorageCredentials configuration, String prefix, String connectionURI) { public MongoDao(LuckPermsPlugin plugin, StorageCredentials configuration, String prefix, String connectionUri) {
super(plugin, "MongoDB"); super(plugin, "MongoDB");
this.configuration = configuration; this.configuration = configuration;
this.prefix = prefix; this.prefix = prefix;
this.connectionURI = connectionURI; this.connectionUri = connectionUri;
} }
@Override @Override
public void init() { public void init() {
if (!Strings.isNullOrempty(this.connectionURI)) { if (!Strings.isNullOrEmpty(this.connectionUri)) {
this.mongoClient = new MongoClient(new MongoClientURI(this.connectionURI)); this.mongoClient = new MongoClient(new MongoClientURI(this.connectionUri));
} else { } else {
MongoCredential credential = null; MongoCredential credential = null;
if (!Strings.isNullOrEmpty(this.configuration.getUsername())) { if (!Strings.isNullOrEmpty(this.configuration.getUsername())) {

View File

@@ -328,7 +328,7 @@ data:
# The prefix to use for all LuckPerms collections. Change this if you want to use different # The prefix to use for all LuckPerms collections. Change this if you want to use different
# collections for different servers. The default is no prefix. # collections for different servers. The default is no prefix.
mongodb_collection_prefix: '' mongodb_collection_prefix: ''
# MongoDB ClientConnectionURI for use with replicasets and custom connection options # MongoDB ClientConnectionURI for use with replicasets and custom connection options
# See https://docs.mongodb.com/manual/reference/connection-string/ # See https://docs.mongodb.com/manual/reference/connection-string/
mongodb_connection_URI: '' mongodb_connection_URI: ''

View File

@@ -277,7 +277,7 @@ data {
# The prefix to use for all LuckPerms collections. Change this if you want to use different # The prefix to use for all LuckPerms collections. Change this if you want to use different
# collections for different servers. The default is no prefix. # collections for different servers. The default is no prefix.
mongodb_collection_prefix="" mongodb_collection_prefix=""
# MongoDB ClientConnectionURI for use with replicasets and custom connection options # MongoDB ClientConnectionURI for use with replicasets and custom connection options
# See https://docs.mongodb.com/manual/reference/connection-string/ # See https://docs.mongodb.com/manual/reference/connection-string/
mongodb_connection_URI="" mongodb_connection_URI=""