forked from MinecraftUtilities/Backend
fix skin part tests
This commit is contained in:
parent
a1ad295e0c
commit
e788ae003f
@ -5,6 +5,7 @@ import cc.fascinated.common.PlayerUtils;
|
|||||||
import cc.fascinated.common.Tuple;
|
import cc.fascinated.common.Tuple;
|
||||||
import cc.fascinated.common.UUIDUtils;
|
import cc.fascinated.common.UUIDUtils;
|
||||||
import cc.fascinated.config.Config;
|
import cc.fascinated.config.Config;
|
||||||
|
import cc.fascinated.exception.impl.BadRequestException;
|
||||||
import cc.fascinated.exception.impl.MojangAPIRateLimitException;
|
import cc.fascinated.exception.impl.MojangAPIRateLimitException;
|
||||||
import cc.fascinated.exception.impl.RateLimitException;
|
import cc.fascinated.exception.impl.RateLimitException;
|
||||||
import cc.fascinated.exception.impl.ResourceNotFoundException;
|
import cc.fascinated.exception.impl.ResourceNotFoundException;
|
||||||
@ -132,9 +133,8 @@ public class PlayerService {
|
|||||||
size = 512;
|
size = 512;
|
||||||
}
|
}
|
||||||
ISkinPart part = ISkinPart.getByName(partName); // The skin part to get
|
ISkinPart part = ISkinPart.getByName(partName); // The skin part to get
|
||||||
if (part == null) { // Default to the face
|
if (part == null) {
|
||||||
part = ISkinPart.Vanilla.FACE;
|
throw new BadRequestException("Invalid skin part: %s".formatted(partName));
|
||||||
log.warn("Invalid skin part {}, defaulting to {}", partName, part.name());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
log.info("Getting skin part {} for player: {}", part.name(), player.getUniqueId());
|
log.info("Getting skin part {} for player: {}", part.name(), player.getUniqueId());
|
||||||
|
Loading…
Reference in New Issue
Block a user