Skip to content
This repository has been archived by the owner on Apr 28, 2020. It is now read-only.

Commit

Permalink
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/Server.php
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,7 @@ public function sendArgumentsToAllMethods($flag = null)
return $this->sendArgumentsToAllMethods;
}

$this->sendArgumentsToAllMethods = (bool)$flag;
$this->sendArgumentsToAllMethods = (bool) $flag;
return $this;
}

Expand Down
4 changes: 2 additions & 2 deletions src/Value/Boolean.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public function __construct($value)
$this->type = self::XMLRPC_TYPE_BOOLEAN;
// Make sure the value is boolean and then convert it into a integer
// The double conversion is because a bug in the ZendOptimizer in PHP version 5.0.4
$this->value = (int)(bool)$value;
$this->value = (int)(bool) $value;
}

/**
Expand All @@ -39,6 +39,6 @@ public function __construct($value)
*/
public function getValue()
{
return (bool)$this->value;
return (bool) $this->value;
}
}
2 changes: 1 addition & 1 deletion src/Value/DateTime.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public function __construct($value)
if ($value instanceof \DateTime) {
$this->value = $value->format($this->phpFormatString);
} elseif (is_numeric($value)) { // The value is numeric, we make sure it is an integer
$this->value = date($this->phpFormatString, (int)$value);
$this->value = date($this->phpFormatString, (int) $value);
} else {
try {
$dateTime = new \DateTime($value);
Expand Down
6 changes: 3 additions & 3 deletions src/Value/Double.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ class Double extends AbstractScalar
public function __construct($value)
{
$this->type = self::XMLRPC_TYPE_DOUBLE;
$precision = (int)ini_get('precision');
$precision = (int) ini_get('precision');
$formatString = '%1.' . $precision . 'F';
$this->value = rtrim(sprintf($formatString, (float)$value), '0');
$this->value = rtrim(sprintf($formatString, (float) $value), '0');
}

/**
Expand All @@ -38,6 +38,6 @@ public function __construct($value)
*/
public function getValue()
{
return (float)$this->value;
return (float) $this->value;
}
}
2 changes: 1 addition & 1 deletion src/Value/Integer.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public function __construct($value)
}

$this->type = self::XMLRPC_TYPE_INTEGER;
$this->value = (int)$value; // Make sure this value is integer
$this->value = (int) $value; // Make sure this value is integer
}

/**
Expand Down
4 changes: 2 additions & 2 deletions src/Value/String.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public function __construct($value)
$this->type = self::XMLRPC_TYPE_STRING;

// Make sure this value is string and all XML characters are encoded
$this->value = (string)$value;
$this->value = (string) $value;
}

/**
Expand All @@ -37,6 +37,6 @@ public function __construct($value)
*/
public function getValue()
{
return (string)$this->value;
return (string) $this->value;
}
}

0 comments on commit 5dc9449

Please # to comment.