mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-08-06 06:57:25 +02:00
some more code examples
This commit is contained in:
@@ -14,11 +14,11 @@ class User
|
||||
protected $username;
|
||||
protected $email;
|
||||
|
||||
public function __construct(array $options = null)
|
||||
public function __construct($id, $username, $email)
|
||||
{
|
||||
if (is_array($options)) {
|
||||
$this->setOptions($options);
|
||||
}
|
||||
$this->id = $id;
|
||||
$this->username = $username;
|
||||
$this->email = $email;
|
||||
}
|
||||
|
||||
public function getUserId() {
|
||||
|
Reference in New Issue
Block a user