Make the ITimeFactory strict + return types
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
parent
1faef0c459
commit
7ffd62bf95
|
@ -1,4 +1,5 @@
|
|||
<?php
|
||||
declare(strict_types=1);
|
||||
/**
|
||||
* @copyright Copyright (c) 2016, ownCloud, Inc.
|
||||
*
|
||||
|
@ -22,7 +23,6 @@
|
|||
*
|
||||
*/
|
||||
|
||||
|
||||
namespace OC\AppFramework\Utility;
|
||||
|
||||
use OCP\AppFramework\Utility\ITimeFactory;
|
||||
|
@ -37,7 +37,7 @@ class TimeFactory implements ITimeFactory {
|
|||
/**
|
||||
* @return int the result of a call to time()
|
||||
*/
|
||||
public function getTime() {
|
||||
public function getTime() : int {
|
||||
return time();
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
<?php
|
||||
declare(strict_types=1);
|
||||
/**
|
||||
* @copyright Copyright (c) 2016, ownCloud, Inc.
|
||||
*
|
||||
|
@ -21,7 +22,6 @@
|
|||
*
|
||||
*/
|
||||
|
||||
|
||||
namespace OCP\AppFramework\Utility;
|
||||
|
||||
|
||||
|
@ -35,6 +35,6 @@ interface ITimeFactory {
|
|||
* @return int the result of a call to time()
|
||||
* @since 8.0.0
|
||||
*/
|
||||
public function getTime();
|
||||
public function getTime() : int;
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue