diff --git a/src/Application/AbstractApplication.php b/src/Application/AbstractApplication.php
index 1f1da040..d5f55412 100644
--- a/src/Application/AbstractApplication.php
+++ b/src/Application/AbstractApplication.php
@@ -71,7 +71,7 @@ public function getEventsManager(): ?ManagerInterface
* Gets the module definition registered in the application via module name
*
* @param string $name *
- * @return array
+ * @return array|mixed
*/
public function getModule(string $name): array
{
diff --git a/src/Db/Adapter/AdapterInterface.php b/src/Db/Adapter/AdapterInterface.php
index ef7d9ead..7787a3be 100644
--- a/src/Db/Adapter/AdapterInterface.php
+++ b/src/Db/Adapter/AdapterInterface.php
@@ -82,9 +82,9 @@ public function begin(bool $nesting = true): bool;
* Closes active connection returning success. Phalcon automatically closes
* and destroys active connections within Phalcon\Db\Pool
*
- * @return bool
+ * @return void
*/
- public function close(): bool;
+ public function close(): void;
/**
* Commits the active transaction in the connection
@@ -99,9 +99,9 @@ public function commit(bool $nesting = true): bool;
* constructor. Call it when you need to restore a database connection
*
* @param array $descriptor
- * @return bool
+ * @return void
*/
- public function connect(array $descriptor = null): bool;
+ public function connect(array $descriptor = []): void;
/**
* Creates a new savepoint
@@ -486,9 +486,10 @@ public function isUnderTransaction(): bool;
* Returns insert id for the auto_increment column inserted in the last SQL
* statement
*
- * @param mixed $sequenceName
+ * @param string|null $name Name of the sequence object from which the ID should be returned.
+ * @return string|bool
*/
- public function lastInsertId($sequenceName = null);
+ public function lastInsertId(string $name = null);
/**
* Appends a LIMIT clause to sqlQuery argument
diff --git a/src/Db/Adapter/Pdo/AbstractPdo.php b/src/Db/Adapter/Pdo/AbstractPdo.php
index 4f75a290..d2302c12 100644
--- a/src/Db/Adapter/Pdo/AbstractPdo.php
+++ b/src/Db/Adapter/Pdo/AbstractPdo.php
@@ -112,9 +112,9 @@ public function commit(bool $nesting = true): bool
* Closes the active connection returning success. Phalcon automatically
* closes and destroys active connections when the request ends
*
- * @return bool
+ * @return void
*/
- public function close(): bool
+ public function close(): void
{
}
@@ -143,9 +143,9 @@ public function close(): bool
* ```
*
* @param array $descriptor
- * @return bool
+ * @return void
*/
- public function connect(array $descriptor = null): bool
+ public function connect(array $descriptor = []): void
{
}
@@ -248,8 +248,10 @@ public function executePrepared(\PDOStatement $statement, array $placeholders, $
/**
* Return the error info, if any
+ *
+ * @return array
*/
- public function getErrorInfo()
+ public function getErrorInfo(): array
{
}
@@ -311,10 +313,10 @@ public function isUnderTransaction(): bool
* $id = $connection->lastInsertId();
* ```
*
- * @param mixed $sequenceName
- * @return int|bool
+ * @param string|null $name
+ * @return string|bool
*/
- public function lastInsertId($sequenceName = null)
+ public function lastInsertId(string $name = null)
{
}
diff --git a/src/Db/Adapter/Pdo/Postgresql.php b/src/Db/Adapter/Pdo/Postgresql.php
index 64a72896..a7129059 100644
--- a/src/Db/Adapter/Pdo/Postgresql.php
+++ b/src/Db/Adapter/Pdo/Postgresql.php
@@ -63,9 +63,9 @@ public function __construct(array $descriptor)
* constructor. Call it when you need to restore a database connection.
*
* @param array $descriptor
- * @return bool
+ * @return void
*/
- public function connect(array $descriptor = null): bool
+ public function connect(array $descriptor = []): void
{
}
diff --git a/src/Db/Adapter/Pdo/Sqlite.php b/src/Db/Adapter/Pdo/Sqlite.php
index 4b4f6d75..bc0d41a4 100644
--- a/src/Db/Adapter/Pdo/Sqlite.php
+++ b/src/Db/Adapter/Pdo/Sqlite.php
@@ -60,9 +60,9 @@ public function __construct(array $descriptor)
* constructor. Call it when you need to restore a database connection.
*
* @param array $descriptor
- * @return bool
+ * @return void
*/
- public function connect(array $descriptor = null): bool
+ public function connect(array $descriptor = []): void
{
}
diff --git a/src/Dispatcher/AbstractDispatcher.php b/src/Dispatcher/AbstractDispatcher.php
index 53d8ab74..ec84205f 100644
--- a/src/Dispatcher/AbstractDispatcher.php
+++ b/src/Dispatcher/AbstractDispatcher.php
@@ -165,7 +165,7 @@ public function callActionMethod($handler, string $actionMethod, array $params =
* Process the results of the router by calling into the appropriate
* controller action(s) including any routing data or injected parameters.
*
- * @return bool Returns the dispatched handler class (the Controller for Mvc dispatching or a Task
+ * @return mixed Returns the dispatched handler class (the Controller for Mvc dispatching or a Task
* for CLI dispatching) or false if an exception occurred and the operation was
* stopped by returning false in the exception handler.
*
diff --git a/src/Dispatcher/DispatcherInterface.php b/src/Dispatcher/DispatcherInterface.php
index e84b865b..2a2b5a83 100644
--- a/src/Dispatcher/DispatcherInterface.php
+++ b/src/Dispatcher/DispatcherInterface.php
@@ -18,7 +18,7 @@ interface DispatcherInterface
/**
* Dispatches a handle action taking into account the routing parameters
*
- * @return bool
+ * @return mixed
*/
public function dispatch(): bool;
diff --git a/src/Helper/Json.php b/src/Helper/Json.php
index 1ddd0f36..caab0ece 100644
--- a/src/Helper/Json.php
+++ b/src/Helper/Json.php
@@ -67,7 +67,7 @@ final public static function decode(string $data, bool $associative = false, int
* @param int $options Bitmask of JSON decode options.
* @param int $depth Recursion depth.
*
- * @return string
+ * @return mixed
*
* @throws \InvalidArgumentException if the JSON cannot be encoded.
* @link http://www.php.net/manual/en/function.json-encode.php
diff --git a/src/Http/Message/AbstractRequest.php b/src/Http/Message/AbstractRequest.php
index 1f5c23b6..2d7b143a 100644
--- a/src/Http/Message/AbstractRequest.php
+++ b/src/Http/Message/AbstractRequest.php
@@ -44,7 +44,6 @@ abstract class AbstractRequest extends \Phalcon\Http\Message\AbstractMessage imp
/**
- *
* Retrieves the HTTP method of the request.
*
* @return string
@@ -54,7 +53,6 @@ public function getMethod(): string
}
/**
- *
* Retrieves the URI instance.
*
* This method MUST return a UriInterface instance.
diff --git a/src/Http/Message/Response.php b/src/Http/Message/Response.php
index 0515de7d..3304f7f7 100644
--- a/src/Http/Message/Response.php
+++ b/src/Http/Message/Response.php
@@ -48,19 +48,13 @@ final class Response extends AbstractMessage implements \Psr\Http\Message\Respon
/**
- *
* Gets the response reason phrase associated with the status code.
*
* Because a reason phrase is not a required element in a response
- *
* status line, the reason phrase value MAY be empty. Implementations MAY
- *
* choose to return the default RFC 7231 recommended reason phrase (or
- *
* those
- *
* listed in the IANA HTTP Status Code Registry) for the response's
- *
* status code.
*
* @return string
@@ -70,11 +64,9 @@ public function getReasonPhrase(): string
}
/**
- *
* Gets the response status code.
*
* The status code is a 3-digit integer result code of the server's attempt
- *
* to understand and satisfy the request.
*
* @return int
diff --git a/src/Http/Message/ServerRequest.php b/src/Http/Message/ServerRequest.php
index fa91de18..921ad8ab 100644
--- a/src/Http/Message/ServerRequest.php
+++ b/src/Http/Message/ServerRequest.php
@@ -96,13 +96,11 @@ final class ServerRequest extends \Phalcon\Http\Message\AbstractRequest implemen
/**
- *
* Retrieve cookies.
*
* Retrieves cookies sent by the client to the server.
*
* The data MUST be compatible with the structure of the $_COOKIE
- *
* superglobal.
*
* @return array
@@ -112,21 +110,15 @@ public function getCookieParams(): array
}
/**
- *
* Retrieve any parameters provided in the request body.
*
* If the request Content-Type is either application/x-www-form-urlencoded
- *
* or multipart/form-data, and the request method is POST, this method MUST
- *
* return the contents of $_POST.
*
* Otherwise, this method may return any results of deserializing
- *
* the request body content; as parsing returns structured content, the
- *
* potential types MUST be arrays or objects only. A null value indicates
- *
* the absence of body content.
*
* @return mixed
@@ -136,17 +128,13 @@ public function getParsedBody()
}
/**
- *
* Retrieve query string arguments.
*
* Retrieves the deserialized query string arguments, if any.
*
* Note: the query params might not be in sync with the URI or server
- *
* params. If you need to ensure you are only getting the original
- *
* values, you may need to parse the query string from
- *
* `getUri()->getQuery()` or from the `QUERY_STRING` server param.
*
* @return array
@@ -156,13 +144,10 @@ public function getQueryParams(): array
}
/**
- *
* Retrieve server parameters.
*
* Retrieves data related to the incoming request environment,
- *
* typically derived from PHP's $_SERVER superglobal. The data IS NOT
- *
* REQUIRED to originate from $_SERVER.
*
* @return array
@@ -172,15 +157,12 @@ public function getServerParams(): array
}
/**
- *
* Retrieve normalized file upload data.
*
* This method returns upload metadata in a normalized tree, with each leaf
- *
* an instance of Psr\Http\Message\UploadedFileInterface.
*
* These values MAY be prepared from $_FILES or the message body during
- *
* instantiation, or MAY be injected via withUploadedFiles().
*
* @return array
diff --git a/src/Mvc/Model/Binder.php b/src/Mvc/Model/Binder.php
index dff4f177..2644edc5 100644
--- a/src/Mvc/Model/Binder.php
+++ b/src/Mvc/Model/Binder.php
@@ -95,7 +95,7 @@ public function bindToHandler($handler, array $params, string $cacheKey, string
/**
* Find the model by param value.
*
- * @return bool
+ * @return mixed
* @param mixed $paramValue
* @param string $className
*/
diff --git a/src/Security/JWT/Builder.php b/src/Security/JWT/Builder.php
index fd7eb587..99c1ddd0 100644
--- a/src/Security/JWT/Builder.php
+++ b/src/Security/JWT/Builder.php
@@ -69,6 +69,18 @@ public function init(): Builder
{
}
+ /**
+ * Adds a custom claim
+ *
+ * @param string $name
+ * @param mixed $value
+ *
+ * @return Builder
+ */
+ public function addClaim(string $name, $value): Builder
+ {
+ }
+
/**
* @return array|string
*/
diff --git a/src/Storage/Adapter/AbstractAdapter.php b/src/Storage/Adapter/AbstractAdapter.php
index 4eda577f..f4008e78 100644
--- a/src/Storage/Adapter/AbstractAdapter.php
+++ b/src/Storage/Adapter/AbstractAdapter.php
@@ -67,7 +67,6 @@ abstract class AbstractAdapter implements \Phalcon\Storage\Adapter\AdapterInterf
/**
- *
* Name of the default serializer class
*
* @return string
@@ -77,7 +76,6 @@ public function getDefaultSerializer(): string
}
/**
- *
* Name of the default serializer class
*
* @param string $defaultSerializer