Fix issue missing lecture when calling checkin

This commit is contained in:
Joshua Coles 2024-02-04 17:36:39 +00:00
parent 28c3fd27be
commit bee3984a35

View File

@ -3,7 +3,7 @@ class LectureCheckinJob < ApplicationJob
def perform(*args)
lecture = Lecture.find_by(start_time: Time.now - 5.minutes..Time.now + 5.minutes)
return if lecture.empty?
return unless lecture.present?
puts(HTTParty.post(
"https://api.pushcut.io/2Kdtb5V7SoDXQOPxCJetk/notifications/Checkin",