mirror of
https://github.com/PlaceholderAPI/PlaceholderAPI
synced 2025-02-05 15:55:28 +01:00
fix(replacer): Stop lowercasing replacements
This commit changes two lines but fixes the replacement of cased placeholders with non-cased ones that was accidentally happening. This was partially fixed in a few previous commits, but not fully as it was still replacing failed placeholder matches.
This commit is contained in:
parent
bb149811d4
commit
1388a5278f
@ -106,7 +106,7 @@ public final class CharsReplacer implements Replacer {
|
|||||||
|
|
||||||
final PlaceholderExpansion placeholder = lookup.apply(lowercaseIdentifierString);
|
final PlaceholderExpansion placeholder = lookup.apply(lowercaseIdentifierString);
|
||||||
if (placeholder == null) {
|
if (placeholder == null) {
|
||||||
builder.append(closure.head).append(lowercaseIdentifierString);
|
builder.append(closure.head).append(identifierString);
|
||||||
|
|
||||||
if (identified) {
|
if (identified) {
|
||||||
builder.append('_');
|
builder.append('_');
|
||||||
@ -118,7 +118,7 @@ public final class CharsReplacer implements Replacer {
|
|||||||
|
|
||||||
final String replacement = placeholder.onRequest(player, parametersString);
|
final String replacement = placeholder.onRequest(player, parametersString);
|
||||||
if (replacement == null) {
|
if (replacement == null) {
|
||||||
builder.append(closure.head).append(lowercaseIdentifierString);
|
builder.append(closure.head).append(identifierString);
|
||||||
|
|
||||||
if (identified) {
|
if (identified) {
|
||||||
builder.append('_');
|
builder.append('_');
|
||||||
|
Loading…
Reference in New Issue
Block a user