diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index a51f482f2b..81d4e87bc3 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -117,10 +117,8 @@ Appwrite's current structure is a combination of both [Monolithic](https://en.wi │ ├── Extend │ ├── Network │ ├── OpenSSL -│ ├── Preloader │ ├── Resize │ ├── Storage -│ ├── Swoole │ ├── Task │ ├── Template │ ├── URL diff --git a/README.md b/README.md index d7938a3d7b..75ca031af6 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ [![Hacktoberfest](https://badgen.net/badge/hacktoberfest/friendly/pink)](CONTRIBUTING.md) [![Discord](https://img.shields.io/discord/564160730845151244?label=discord)](https://appwrite.io/discord) -[![Docker Pulls](https://badgen.net/docker/pulls/appwrite/appwrite)](https://travis-ci.org/appwrite/appwrite) +[![Docker Pulls](https://badgen.net/docker/pulls/appwrite/appwrite)](https://hub.docker.com/r/appwrite/appwrite) [![Travis CI](https://badgen.net/travis/appwrite/appwrite?label=build)](https://travis-ci.com/appwrite/appwrite) [![Twitter Account](https://badgen.net/twitter/follow/appwrite_io?label=twitter)](https://twitter.com/appwrite_io) [![Follow Appwrite on StackShare](https://badgen.net/badge/follow%20on/stackshare/blue)](https://stackshare.io/appwrite) diff --git a/src/Appwrite/Utopia/Response.php b/src/Appwrite/Utopia/Response.php index cbfd53f3e4..a1b3434461 100644 --- a/src/Appwrite/Utopia/Response.php +++ b/src/Appwrite/Utopia/Response.php @@ -35,6 +35,9 @@ use Appwrite\Utopia\Response\Model\Tag; use Appwrite\Utopia\Response\Model\Task; use Appwrite\Utopia\Response\Model\Webhook; +/** + * @method public function setStatusCode(int $code = 200): Response + */ class Response extends SwooleResponse { // General @@ -221,25 +224,9 @@ class Response extends SwooleResponse * * return void */ - public function dynamic(Document $document, string $model) + public function dynamic(Document $document, string $model): void { - return $this->json($this->output($document, $model)); - } - - /** - * (Mocking method for avoiding IDE errors, remove when possible) - * - * Set status code - * - * Set HTTP response status code between available options. if status code is unknown an exception will be thrown - * - * @param int $code - * @return self - * @throws Exception - */ - public function setStatusCode(int $code = 200): self - { - return $this->setStatusCode($code); + $this->json($this->output($document, $model)); } /**