FML Update 1.4
This commit is contained in:
@ -48,22 +48,31 @@ class ManiaLink {
|
||||
/**
|
||||
* Create a new ManiaLink object
|
||||
*
|
||||
* @param string $maniaLinkId (optional) ManiaLink id
|
||||
* @param string $maniaLinkId (optional) ManiaLink id
|
||||
* @param string $maniaLinkName (optional) ManiaLink Name
|
||||
* @return static
|
||||
*/
|
||||
public static function create($maniaLinkId = null) {
|
||||
return new static($maniaLinkId);
|
||||
public static function create($maniaLinkId = null, $maniaLinkName = null) {
|
||||
return new static($maniaLinkId, $maniaLinkName);
|
||||
}
|
||||
|
||||
/**
|
||||
* Construct a new ManiaLink object
|
||||
*
|
||||
* @param string $maniaLinkId (optional) ManiaLink id
|
||||
* @param string $maniaLinkId (optional) ManiaLink id
|
||||
* @param string $maniaLinkName (optional) ManiaLink Name
|
||||
*/
|
||||
public function __construct($maniaLinkId = null) {
|
||||
if (!is_null($maniaLinkId)) {
|
||||
public function __construct($maniaLinkId = null, $maniaLinkName = null) {
|
||||
if ($maniaLinkId !== null) {
|
||||
$this->setId($maniaLinkId);
|
||||
}
|
||||
if ($maniaLinkName !== false) {
|
||||
if ($maniaLinkName) {
|
||||
$this->setName($maniaLinkName);
|
||||
} else {
|
||||
$this->setName($maniaLinkId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user