李帅

1.修复一些bug

......@@ -222,11 +222,11 @@ class AdminMakeImmerse implements ShouldQueue
$default = $this->adminMakeVideo->poem2->title . "\n" . $this->adminMakeVideo->poem2->author;
$contents[] = $this->autoCenter($default,$font_size, $this->output_width);
foreach ($this->adminMakeVideo->poem2->verses as $item) {
if ($item->content != '') $contents[] = $this->autoEnter($item->content, $font_size, $this->output_width);
$source = " " . "\n" . $item->source;
if ($item->content != '') $contents[] = $this->autoEnter($item->content, $font_size, $this->output_width) . "\n" . $this->autoCenter($source, $font_size, $this->output_width);
if ($item->annotate != '') $contents[] = $this->autoEnter($item->annotate, $font_size, $this->output_width);
if ($item->spelling != '') $contents[] = $this->autoEnter($item->spelling, $font_size, $this->output_width);
if ($item->en != '') $contents[] = $this->autoEnter($item->en, $font_size, $this->output_width);
if ($item->source != '') $contents[] = $this->autoEnter($item->source, $font_size, $this->output_width);
}
break;
case 'weather':
......@@ -330,7 +330,7 @@ class AdminMakeImmerse implements ShouldQueue
$video_width = $video_width - 2 * $font_width; // 两侧留出空隙
$row_count = floor($video_width / $font_width);
$arr = explode("\n", $string);
$title = $arr[0];
$title = $arr[0] ?? " ";
$author = $arr[1];
$title_len = mb_strlen($title);
......