mirror of
https://github.com/mat-1/azalea.git
synced 2025-08-02 14:26:04 +00:00
fix panic in azalea-chat i hope
This commit is contained in:
parent
8215331381
commit
67dc5b367f
1 changed files with 1 additions and 1 deletions
|
@ -55,7 +55,7 @@ impl TranslatableComponent {
|
|||
let mut built_text = String::new();
|
||||
let mut components = Vec::new();
|
||||
|
||||
while i < template.len() {
|
||||
while i < template.chars().count() {
|
||||
if template.chars().nth(i).unwrap() == '%' {
|
||||
let Some(char_after) = template.chars().nth(i + 1) else {
|
||||
built_text.push(template.chars().nth(i).unwrap());
|
||||
|
|
Loading…
Add table
Reference in a new issue