Added response to every path

This commit is contained in:
Maximilian Giller 2021-01-01 16:35:17 +01:00
parent 2dbf32cd9e
commit 1be0761358
5 changed files with 9 additions and 1 deletions

View file

@ -17,6 +17,8 @@ class AddRecordTagBranch extends ApiBranch
$tag_name = $params->get("tag_name");
addRecordTag($user_id, $tag_name);
respondStatus(200);
}
}

View file

@ -17,6 +17,8 @@ class AddTagToRecordBranch extends ApiBranch
$tag_id = $params->get("tag_id");
addTagToRecord($tag_id, $record_id);
respondStatus(200);
}
}

View file

@ -20,6 +20,8 @@ class EndRecordBranch extends ApiBranch
}
updateEndRecord($user_id, $params);
respondStatus(200);
}
}

View file

@ -17,6 +17,8 @@ class RemoveTagFromRecordBranch extends ApiBranch
$tag_id = $params->get("tag_id");
removeTagFromRecord($tag_id, $record_id);
respondStatus(200);
}
}

View file

@ -1,7 +1,7 @@
<?php
require_once(__DIR__."/jsonBuilder.inc.php");
function defaultHeader()
function setDefaultHeader()
{
header("Access-Control-Allow-Origin: *");
header("Access-Control-Allow-Methods: POST, GET, OPTIONS");