Issues (215)

src/Models/Model.php (4 issues)

1
<?php
2
3
namespace GloBee\PaymentApi\Models;
4
5
use GloBee\PaymentApi\Exceptions\UnknownPropertyException;
6
7
abstract class Model
8
{
9
    /**
0 ignored issues
show
Coding Style Documentation introduced by
Doc comment for parameter "$name" missing
Loading history...
10
     * @param $name
0 ignored issues
show
Missing parameter name
Loading history...
11
     *
12
     * @return mixed
13
     * @throws UnknownPropertyException
0 ignored issues
show
Comment missing for @throws tag in function comment
Loading history...
14
     */
15 15
    public function __get($name)
0 ignored issues
show
Type hint "name" missing for
Loading history...
16
    {
17 15
        if (property_exists($this, $name)) {
18 14
            return $this->{$name};
19
        }
20
21 1
        throw new UnknownPropertyException($name);
22
    }
23
}
24