From 37b2fca2fd31f0a87a5648da5de2029e59c0a004 Mon Sep 17 00:00:00 2001 From: Kavin <20838718+FireMasterK@users.noreply.github.com> Date: Fri, 28 Jul 2023 11:50:21 +0100 Subject: [PATCH] Fix type mismatch error. --- src/main/java/me/kavin/piped/utils/VideoHelpers.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/me/kavin/piped/utils/VideoHelpers.java b/src/main/java/me/kavin/piped/utils/VideoHelpers.java index 7984246..6c80834 100644 --- a/src/main/java/me/kavin/piped/utils/VideoHelpers.java +++ b/src/main/java/me/kavin/piped/utils/VideoHelpers.java @@ -164,14 +164,15 @@ public class VideoHelpers { "(:uploader_id,:duration,:is_short,:thumbnail,:title,:uploaded,:views,:id) ON CONFLICT (id) DO UPDATE SET " + "duration = excluded.duration, title = excluded.title, views = excluded.views" ) - .setParameter("uploader_id", video.getChannel()) + .setParameter("uploader_id", video.getChannel().getUploaderId()) .setParameter("duration", video.getDuration()) .setParameter("is_short", video.isShort()) .setParameter("thumbnail", video.getThumbnail()) .setParameter("title", video.getTitle()) .setParameter("uploaded", video.getUploaded()) .setParameter("views", video.getViews()) - .setParameter("id", video.getId()).executeUpdate(); + .setParameter("id", video.getId()) + .executeUpdate(); tr.commit(); } catch (Exception e) { tr.rollback();