return block

This commit is contained in:
afornerot 2024-04-12 22:31:02 +02:00
parent b530a4d8ff
commit 0b15ea51bd
1 changed files with 1 additions and 1 deletions

View File

@ -337,7 +337,7 @@ class giteaService
$body = \Unirest\Request\Body::json($query);
$body=str_replace('"'.$toblock.'"',$toblock,$body);
$response=$this->api("POST",$apiurl,$body,$this->session->get("giteatoken"));
if(!$response||$response->code!="200") return false;
if(!$response||($response->code!="200"&&$response->code!="201")) return false;
else return $response->body;
}