mirror of
https://github.com/Mercantec-GHC/h4-projekt-gruppe-0-sm.git
synced 2025-04-27 08:24:05 +02:00
fix error on empty receipts vec
This commit is contained in:
parent
f0c0ad5766
commit
c729175a28
@ -97,6 +97,7 @@ void route_get_receipts_all(HttpCtx* ctx)
|
||||
|
||||
String receipts_str;
|
||||
string_construct(&receipts_str);
|
||||
string_push_str(&receipts_str, "");
|
||||
for (size_t i = 0; i < receipts.size; ++i) {
|
||||
if (i != 0) {
|
||||
string_pushf(&receipts_str, ",");
|
||||
|
Loading…
x
Reference in New Issue
Block a user