Skip to content

Commit

Permalink
fix(server): Return all jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
pando85 committed Jan 21, 2024
1 parent 5112eec commit bcae0c9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions scripts/test-upload.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ echo "Upload job"
curl -s --location --request POST "${JOBS_URL}" \
--header 'Content-Type: text/plain' \
--data "$data"
echo -e '\n'

MAX_ATTEMPTS=50
for attempt in $(seq 1 $MAX_ATTEMPTS); do
Expand Down
2 changes: 1 addition & 1 deletion server/repository/repository.go
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ func (S *SQLRepository) getJobs(ctx context.Context, tx Transaction) (*[]model.V
return nil, err
}
videos := []model.Video{}
if rows.Next() {
for rows.Next() {
video := model.Video{}
rows.Scan(&video.Id)
videos = append(videos, video)
Expand Down

0 comments on commit bcae0c9

Please sign in to comment.