mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2025-06-29 20:24:43 +02:00
Fixed #399
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
package com.intellectualcrafters.plot.util;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
@ -20,4 +21,12 @@ public class StringMan {
|
||||
}
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
public static String replaceAll(String string, Object... pairs) {
|
||||
HashMap<String, String> replacements = new HashMap<>();
|
||||
for (int i = 0; i < pairs.length; i+=2) {
|
||||
replacements.put(pairs[i] + "", pairs[i+1] + "");
|
||||
}
|
||||
return replaceFromMap(string, replacements);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user