mirror of
https://github.com/AuthMe/AuthMeReloaded.git
synced 2024-11-23 18:55:11 +01:00
cleanup
This commit is contained in:
parent
6dc4119d0c
commit
f6e9347e1e
@ -81,8 +81,7 @@ public class API {
|
||||
PlayerAuth auth = PlayerCache.getInstance().getAuth(player.getName().toLowerCase());
|
||||
|
||||
if (auth != null) {
|
||||
Location loc = new Location(Bukkit.getWorld(auth.getWorld()), auth.getQuitLocX(), auth.getQuitLocY(), auth.getQuitLocZ());
|
||||
return loc;
|
||||
return new Location(Bukkit.getWorld(auth.getWorld()), auth.getQuitLocX(), auth.getQuitLocY(), auth.getQuitLocZ());
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
|
@ -41,8 +41,7 @@ public class EssSpawn extends CustomConfiguration {
|
||||
return null;
|
||||
if (this.getString("spawns.default.world").isEmpty() || this.getString("spawns.default.world").equals(""))
|
||||
return null;
|
||||
Location location = new Location(Bukkit.getWorld(this.getString("spawns.default.world")), this.getDouble("spawns.default.x"), this.getDouble("spawns.default.y"), this.getDouble("spawns.default.z"), Float.parseFloat(this.getString("spawns.default.yaw")), Float.parseFloat(this.getString("spawns.default.pitch")));
|
||||
return location;
|
||||
return new Location(Bukkit.getWorld(this.getString("spawns.default.world")), this.getDouble("spawns.default.x"), this.getDouble("spawns.default.y"), this.getDouble("spawns.default.z"), Float.parseFloat(this.getString("spawns.default.yaw")), Float.parseFloat(this.getString("spawns.default.pitch")));
|
||||
} catch (NullPointerException | NumberFormatException npe) {
|
||||
return null;
|
||||
}
|
||||
|
@ -378,7 +378,7 @@ public class BCRYPT implements EncryptionMethod {
|
||||
* @param lr an array containing the two 32-bit half blocks
|
||||
* @param off the position in the array of the blocks
|
||||
*/
|
||||
private final void encipher(int lr[], int off) {
|
||||
private void encipher(int lr[], int off) {
|
||||
int i, n, l = lr[off], r = lr[off + 1];
|
||||
|
||||
l ^= P[0];
|
||||
|
@ -87,8 +87,7 @@ public class MacBasedPRF implements PRF {
|
||||
* @return byte[] * @see fr.xephi.authme.security.pbkdf2.PRF#doFinal(byte[])
|
||||
*/
|
||||
public byte[] doFinal(byte[] M) {
|
||||
byte[] r = mac.doFinal(M);
|
||||
return r;
|
||||
return mac.doFinal(M);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -69,7 +69,6 @@ public class PBKDF2HexFormatter implements PBKDF2Formatter {
|
||||
* @return String * @see fr.xephi.authme.security.pbkdf2.PBKDF2Formatter#toString(PBKDF2Parameters)
|
||||
*/
|
||||
public String toString(PBKDF2Parameters p) {
|
||||
String s = BinTools.bin2hex(p.getSalt()) + ":" + String.valueOf(p.getIterationCount()) + ":" + BinTools.bin2hex(p.getDerivedKey());
|
||||
return s;
|
||||
return BinTools.bin2hex(p.getSalt()) + ":" + String.valueOf(p.getIterationCount()) + ":" + BinTools.bin2hex(p.getDerivedKey());
|
||||
}
|
||||
}
|
||||
|
@ -117,8 +117,7 @@ public class Spawn extends CustomConfiguration {
|
||||
try {
|
||||
if (this.getString("spawn.world").isEmpty() || this.getString("spawn.world").equals(""))
|
||||
return null;
|
||||
Location location = new Location(Bukkit.getWorld(this.getString("spawn.world")), this.getDouble("spawn.x"), this.getDouble("spawn.y"), this.getDouble("spawn.z"), Float.parseFloat(this.getString("spawn.yaw")), Float.parseFloat(this.getString("spawn.pitch")));
|
||||
return location;
|
||||
return new Location(Bukkit.getWorld(this.getString("spawn.world")), this.getDouble("spawn.x"), this.getDouble("spawn.y"), this.getDouble("spawn.z"), Float.parseFloat(this.getString("spawn.yaw")), Float.parseFloat(this.getString("spawn.pitch")));
|
||||
} catch (NullPointerException | NumberFormatException npe) {
|
||||
return null;
|
||||
}
|
||||
@ -133,8 +132,7 @@ public class Spawn extends CustomConfiguration {
|
||||
try {
|
||||
if (this.getString("firstspawn.world").isEmpty() || this.getString("firstspawn.world").equals(""))
|
||||
return null;
|
||||
Location location = new Location(Bukkit.getWorld(this.getString("firstspawn.world")), this.getDouble("firstspawn.x"), this.getDouble("firstspawn.y"), this.getDouble("firstspawn.z"), Float.parseFloat(this.getString("firstspawn.yaw")), Float.parseFloat(this.getString("firstspawn.pitch")));
|
||||
return location;
|
||||
return new Location(Bukkit.getWorld(this.getString("firstspawn.world")), this.getDouble("firstspawn.x"), this.getDouble("firstspawn.y"), this.getDouble("firstspawn.z"), Float.parseFloat(this.getString("firstspawn.yaw")), Float.parseFloat(this.getString("firstspawn.pitch")));
|
||||
} catch (NullPointerException | NumberFormatException npe) {
|
||||
return null;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user