diff --git a/www/main.js b/www/main.js index 72c14f1..cd0d344 100644 --- a/www/main.js +++ b/www/main.js @@ -468,7 +468,7 @@ class CanvasController { const wrap_by_space = (text, max_length) => { let split_pos = text.lastIndexOf(" ", max_length); - if (split_pos == 0) { split_pos = max_length; } + if (split_pos <= 0) { split_pos = max_length; } return [text.slice(0, split_pos).trim(), text.slice(split_pos, text.length).trim()]; }