fix: passing null as amount
continuous-integration/drone/pr Build is passing Details

This commit is contained in:
kolaente 2021-12-04 21:14:25 +01:00
parent fbeeff6e59
commit 88a115a6b0
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
1 changed files with 1 additions and 1 deletions

View File

@ -69,7 +69,7 @@ export default class TaskService extends AbstractService {
// Make the repeating amount to seconds
let repeatAfterSeconds = 0
if (model.repeatAfter.amount !== null || model.repeatAfter.amount !== 0) {
if (model.repeatAfter !== null && (model.repeatAfter.amount !== null || model.repeatAfter.amount !== 0)) {
switch (model.repeatAfter.type) {
case 'hours':
repeatAfterSeconds = model.repeatAfter.amount * 60 * 60