Skip to content
Permalink
Browse files

remove unused variables/lines

detected by scrutinizer
  • Loading branch information...
antograssiot committed Feb 27, 2016
1 parent b19dd06 commit df6b8483893439ae4527e678fc6b963e76f43dae
@@ -303,7 +303,7 @@ public function dateAgoInWords(DatetimeInterface $date, array $options = [])
}
$diffData = $this->_diffData($futureTime, $pastTime, $backwards, $options);
list($fNum, $fWord, $years, $months, $weeks, $days, $hours, $minutes, $seconds) = array_values($diffData);
list($fNum, $fWord, $years, $months, $weeks, $days) = array_values($diffData);
$relativeDate = [];
if ($fNum >= 1 && $years > 0) {
@@ -324,7 +324,7 @@ public function write($data)
}
}
$totalBytes = strlen($data);
for ($written = 0, $rv = 0; $written < $totalBytes; $written += $rv) {
for ($written = 0; $written < $totalBytes; $written += $rv) {
$rv = fwrite($this->connection, substr($data, $written));
if ($rv === false || $rv === 0) {
return $written;
@@ -977,7 +977,6 @@ protected function _addDefaultFields()
protected function _addDefaultSelectTypes()
{
$typeMap = $this->typeMap()->defaults();
$selectTypeMap = $this->selectTypeMap();
$select = $this->clause('select');
$types = [];
@@ -481,7 +481,6 @@ protected function _assertAttributes($assertions, $string, $fullDebug = false, $
{
$asserts = $assertions['attrs'];
$explains = $assertions['explains'];
$len = count($asserts);
do {
$matches = false;
foreach ($asserts as $j => $assert) {
@@ -58,7 +58,6 @@ class HtmlHelperTest extends TestCase
public function setUp()
{
parent::setUp();
$controller = $this->getMock('Cake\Controller\Controller', ['redirect']);
$this->View = $this->getMock('Cake\View\View', ['append']);
$this->Html = new HtmlHelper($this->View);
$this->Html->request = new Request();

0 comments on commit df6b848

Please sign in to comment.
You can’t perform that action at this time.