Commit 5ff4312
committed
Fix double-jailing bug and add admin jail time checking
BUG FIXES:
- Prevent jailing already-jailed players (was overwriting jail data)
- Show clear error with remaining time: 'Player is already jailed! Remaining time: X. Use /jail release first.'
NEW FEATURE:
- Add /jail time <player> for admins to check any player's jail time
- Regular players can only use /jail time (self-only)
- Admins need oldschooljail.jail permission to check others
- Clear error messages for permissions and non-jailed players
DOCUMENTATION:
- Updated README with new /jail time <player> command
- Added permission explanation for admin jail time checking
This prevents data corruption and gives admins better jail management tools.1 parent adaaec0 commit 5ff4312
File tree
2 files changed
+41
-3
lines changed- src/main/java/com/oldschooljail/command
2 files changed
+41
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
| 38 | + | |
| 39 | + | |
39 | 40 | | |
40 | 41 | | |
41 | 42 | | |
| |||
53 | 54 | | |
54 | 55 | | |
55 | 56 | | |
| 57 | + | |
56 | 58 | | |
57 | 59 | | |
58 | 60 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
81 | 84 | | |
82 | 85 | | |
83 | 86 | | |
| |||
136 | 139 | | |
137 | 140 | | |
138 | 141 | | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
139 | 152 | | |
140 | 153 | | |
141 | 154 | | |
| |||
147 | 160 | | |
148 | 161 | | |
149 | 162 | | |
150 | | - | |
151 | 163 | | |
152 | 164 | | |
153 | 165 | | |
| |||
333 | 345 | | |
334 | 346 | | |
335 | 347 | | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
336 | 372 | | |
337 | 373 | | |
338 | 374 | | |
| |||
0 commit comments