Adds type hinting for scalar types in ICrypto->decrypt

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
This commit is contained in:
Morris Jobke 2018-01-12 16:30:35 +01:00
parent 16f4d71efd
commit ca28df6fcc
No known key found for this signature in database
GPG Key ID: FE03C3A163FEDE68
2 changed files with 2 additions and 2 deletions

View File

@ -108,7 +108,7 @@ class Crypto implements ICrypto {
* @return string plaintext
* @throws \Exception If the HMAC does not match
*/
public function decrypt($authenticatedCiphertext, $password = '') {
public function decrypt(string $authenticatedCiphertext, string $password = ''): string {
if($password === '') {
$password = $this->config->getSystemValue('secret');
}

View File

@ -61,5 +61,5 @@ interface ICrypto {
* @throws \Exception If the HMAC does not match
* @since 8.0.0
*/
public function decrypt($authenticatedCiphertext, $password = '');
public function decrypt(string $authenticatedCiphertext, string $password = ''): string;
}