Skip to content

Commit

Permalink
Remove unusued parameter $crlf
Browse files Browse the repository at this point in the history
Signed-off-by: Kamil Tekiela <tekiela246@gmail.com>
  • Loading branch information
kamil-tekiela committed Dec 1, 2021
1 parent c3223a9 commit a53f6cc
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 7 deletions.
4 changes: 1 addition & 3 deletions libraries/classes/Plugins/Export/ExportSql.php
Expand Up @@ -1873,7 +1873,6 @@ public function getTableDef(
*
* @param string $db database name
* @param string $table table name
* @param string $crlf end of line sequence
* @param bool $doRelation whether to include relation comments
* @param bool $doMime whether to include mime comments
* @param array $aliases Aliases of db/table/columns
Expand All @@ -1883,7 +1882,6 @@ public function getTableDef(
private function getTableComments(
$db,
$table,
$crlf,
$doRelation = false,
$doMime = false,
array $aliases = []
Expand Down Expand Up @@ -2084,7 +2082,7 @@ public function exportStructure(
);
$dump .= $this->exportComment();
$dump .= $this->getTableDef($db, $table, $crlf, $errorUrl, $dates, true, false, true, $aliases);
$dump .= $this->getTableComments($db, $table, $crlf, $relation, $mime, $aliases);
$dump .= $this->getTableComments($db, $table, $relation, $mime, $aliases);
break;
case 'triggers':
$dump = '';
Expand Down
3 changes: 0 additions & 3 deletions psalm-baseline.xml
Expand Up @@ -10483,9 +10483,6 @@
<UnusedForeachValue occurrences="1">
<code>$name</code>
</UnusedForeachValue>
<UnusedParam occurrences="1">
<code>$crlf</code>
</UnusedParam>
<UnusedVariable occurrences="2">
<code>$autoIncrement</code>
<code>$autoIncrement</code>
Expand Down
2 changes: 1 addition & 1 deletion test/classes/Plugins/Export/ExportSqlTest.php
Expand Up @@ -995,7 +995,7 @@ public function testGetTableComments(): void

$method = new ReflectionMethod(ExportSql::class, 'getTableComments');
$method->setAccessible(true);
$result = $method->invoke($this->object, 'db', '', "\n", true, true);
$result = $method->invoke($this->object, 'db', '', true, true);

$this->assertStringContainsString(
"-- MEDIA TYPES FOR TABLE :\n" .
Expand Down

0 comments on commit a53f6cc

Please sign in to comment.