mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-02-07 04:58:40 +00:00
Adjusting return types
This commit is contained in:
parent
75991ad800
commit
6b883b63ef
|
|
@ -116,7 +116,7 @@ class Commit
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
* @author Dennis Eichhorn <d.eichhorn@oms.com>
|
* @author Dennis Eichhorn <d.eichhorn@oms.com>
|
||||||
*/
|
*/
|
||||||
public function getId()
|
public function getId() : string
|
||||||
{
|
{
|
||||||
return $this->id;
|
return $this->id;
|
||||||
}
|
}
|
||||||
|
|
@ -126,16 +126,20 @@ class Commit
|
||||||
*
|
*
|
||||||
* @param string $path File path
|
* @param string $path File path
|
||||||
*
|
*
|
||||||
|
* @return bool
|
||||||
|
*
|
||||||
* @since 1.0.0
|
* @since 1.0.0
|
||||||
* @author Dennis Eichhorn <d.eichhorn@oms.com>
|
* @author Dennis Eichhorn <d.eichhorn@oms.com>
|
||||||
*/
|
*/
|
||||||
public function addFile(string $path)
|
public function addFile(string $path) : bool
|
||||||
{
|
{
|
||||||
$path = escapeshellarg($path);
|
|
||||||
|
|
||||||
if (!isset($this->files[$path])) {
|
if (!isset($this->files[$path])) {
|
||||||
$this->files[$path] = [];
|
$this->files[$path] = [];
|
||||||
|
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user