summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/Config/Controls.php2
-rw-r--r--test/ControlsTest.php4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/Config/Controls.php b/src/Config/Controls.php
index 88d390b..92e177d 100644
--- a/src/Config/Controls.php
+++ b/src/Config/Controls.php
@@ -145,7 +145,7 @@ trait Controls
arsort($res, SORT_NUMERIC);
- return array_flip(array_filter($res));
+ return array_filter($res);
}
/**
diff --git a/test/ControlsTest.php b/test/ControlsTest.php
index 3976499..f8b8d63 100644
--- a/test/ControlsTest.php
+++ b/test/ControlsTest.php
@@ -51,7 +51,7 @@ class ControlsTest extends PHPUnit_Framework_TestCase
public function testDetectDelimiterList()
{
- $this->assertSame([4 => ','], $this->csv->detectDelimiterList());
+ $this->assertSame([',' => 4], $this->csv->detectDelimiterList());
}
public function testBOMSettings()
@@ -125,7 +125,7 @@ class ControlsTest extends PHPUnit_Framework_TestCase
$data->fputcsv(['toto', 'tata', 'tutu']);
$csv = Writer::createFromFileObject($data);
- $this->assertSame([12 => '|', 4 => ';'], $csv->detectDelimiterList(5, ['|']));
+ $this->assertSame(['|' => 12, ';' => 4], $csv->detectDelimiterList(5, ['|']));
}
/**