| Conditions | 3 |
| Paths | 3 |
| Total Lines | 21 |
| Code Lines | 15 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 42 | public function loadData( |
||
| 43 | string $table, |
||
| 44 | string $filename, |
||
| 45 | array $fields, |
||
| 46 | string $mode |
||
| 47 | ): string { |
||
| 48 | $fields = implode(', ', $fields); |
||
| 49 | |||
| 50 | if ($this->pretend === false) { |
||
| 51 | if ($mode === 'update') { |
||
| 52 | $this->conn->query("TRUNCATE {$table}"); |
||
| 53 | } |
||
| 54 | $pdo = $this->conn->getWrappedConnection(); |
||
| 55 | $pdo->pgsqlCopyFromFile($table, $filename, '|', '\\\\N', $fields); |
||
|
|
|||
| 56 | } |
||
| 57 | |||
| 58 | $sql = "COPY {$table} ($fields) FROM '{$filename}' "; |
||
| 59 | $sql.= '... Managed by pgsqlCopyFromFile'; |
||
| 60 | |||
| 61 | return $sql; |
||
| 62 | } |
||
| 63 | } |
||
| 64 |
This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.
This is most likely a typographical error or the method has been renamed.