From e292a17ac76ebf0c71cccf2e07edf3c53615e0e0 Mon Sep 17 00:00:00 2001 From: rafa_99 Date: Wed, 1 Sep 2021 21:27:00 +0100 Subject: Fixed Misspell --- libs/json.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libs/json.c b/libs/json.c index 280c26e..eb92cce 100644 --- a/libs/json.c +++ b/libs/json.c @@ -88,7 +88,7 @@ Video* generateVideos(json_object* contents) Video *videos = (Video *) calloc(videoCounter(contents), sizeof(Video)); - for ( int i = 0, k = 0; i < json_object_array_length(contents); i++ ) + for ( int i = 0, j = 0; i < json_object_array_length(contents); i++ ) { // Initializing Vars For Each Video Structure char title[TITLE + 1], author[AUTHOR + 1], id[VIDEOID + 1], duration[DURATION + 1]; @@ -115,7 +115,7 @@ Video* generateVideos(json_object* contents) ( json_object_get_type(dataHolder) != json_type_null ) ? strcpy(duration, json_object_get_string(dataHolder)) : strcpy(duration, "LIVE NOW") ; // Creating Videos Data - videos[k++] = createVideo(title, author, id, duration); + videos[j++] = createVideo(title, author, id, duration); } } -- cgit v1.2.3