Skip to content

Commit 27bf487

Browse files
committed
fix: check twitch option before returning
1 parent 422bbfd commit 27bf487

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

  • bathbot/src/manager/redis

bathbot/src/manager/redis/mod.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -425,6 +425,10 @@ const _: () = {
425425
}
426426
}
427427

428+
if stream.is_none() {
429+
return Ok(None);
430+
}
431+
428432
CachedArchive::new(bytes)
429433
.map(Some)
430434
.map_err(RedisError::Validation)
@@ -473,6 +477,10 @@ const _: () = {
473477
}
474478
}
475479

480+
if vod.is_none() {
481+
return Ok(None);
482+
}
483+
476484
CachedArchive::new(bytes)
477485
.map(Some)
478486
.map_err(RedisError::Validation)

0 commit comments

Comments
 (0)