pinakes-core: fix subtitle i32 overflow in postgres
Signed-off-by: NotAShelf <raf@notashelf.dev> Change-Id: I3b43f97c96905953fd58f051667c59096a6a6964
This commit is contained in:
parent
60452dcb5a
commit
6d68a83003
4 changed files with 33 additions and 8 deletions
|
|
@ -392,7 +392,13 @@ pub async fn cleanup_orphaned_thumbnails(
|
|||
|
||||
if thumbnail_dir.exists() {
|
||||
let entries = std::fs::read_dir(thumbnail_dir)?;
|
||||
for entry in entries.flatten() {
|
||||
for entry in entries.filter_map(|e| {
|
||||
e.map_err(|err| {
|
||||
warn!(error = %err, "failed to read thumbnail directory entry");
|
||||
err
|
||||
})
|
||||
.ok()
|
||||
}) {
|
||||
let path = entry.path();
|
||||
if let Some(stem) = path.file_stem().and_then(|s| s.to_str())
|
||||
&& !known_ids.contains(stem)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue