Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
kanyxmo committed Mar 2, 2023
2 parents 4e52f38 + 5be1cc7 commit 119c4f9
Show file tree
Hide file tree
Showing 4 changed files with 330 additions and 328 deletions.
4 changes: 2 additions & 2 deletions app/System/Controller/UploadController.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ public function getAllFile(): \Psr\Http\Message\ResponseInterface
#[GetMapping("getFileInfoById")]
public function getFileInfoByid(): \Psr\Http\Message\ResponseInterface
{
return $this->success($this->service->read((int) $this->request->input('id', null)));
return $this->success($this->service->read((int) $this->request->input('id', null)) ?? []);
}

/**
Expand All @@ -126,7 +126,7 @@ public function getFileInfoByid(): \Psr\Http\Message\ResponseInterface
#[GetMapping("getFileInfoByHash")]
public function getFileInfoByHash(): \Psr\Http\Message\ResponseInterface
{
return $this->success($this->service->readByHash($this->request->input('hash', null)));
return $this->success($this->service->readByHash($this->request->input('hash', null)) ?? []);
}

/**
Expand Down
Loading

0 comments on commit 119c4f9

Please sign in to comment.