1
0
mirror of https://github.com/Zrips/Jobs.git synced 2025-01-02 14:29:07 +01:00

Fix archived placeholders not worked with job name context

Fixes #1060
This commit is contained in:
montlikadani 2021-01-16 12:38:58 +01:00
parent 77295b6041
commit da5641ff37

View File

@ -72,8 +72,8 @@ public class Placeholder {
user_jmaxlvl_$1("jname/number"),
user_job_$1("jname/number"),
user_title_$1("jname/number"),
user_archived_jobs_level("jname/number"),
user_archived_jobs_exp("jname/number"),
user_archived_jobs_level_$1("jname/number"),
user_archived_jobs_exp_$1("jname/number"),
maxjobs,
@ -543,14 +543,14 @@ public class Placeholder {
return "";
Title title = Jobs.gettitleManager().getTitle(j.getLevel(), j.getJob().getName());
return title == null ? "" : title.getChatColor() + title.getName();
case user_archived_jobs_level:
case user_archived_jobs_level_$1:
if (j == null) {
return "";
}
JobProgression archivedJobProg = user.getArchivedJobProgression(j.getJob());
return archivedJobProg == null ? "" : Integer.toString(archivedJobProg.getLevel());
case user_archived_jobs_exp:
case user_archived_jobs_exp_$1:
if (j == null) {
return "";
}