mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2024-11-27 19:31:01 -06:00
Some array_keys fixes.
This commit is contained in:
parent
0d198193db
commit
9a53d8c21c
@ -424,7 +424,8 @@ class ImportController extends Controller
|
||||
$type = strtolower($job->file_type);
|
||||
|
||||
// validate type:
|
||||
$validTypes = array_keys('firefly.import_formats');
|
||||
$validTypes = array_keys(config('firefly.import_formats'));
|
||||
|
||||
|
||||
if (in_array($type, $validTypes)) {
|
||||
/** @var SetupInterface $importer */
|
||||
|
@ -123,7 +123,7 @@ class CsvImporter implements ImporterInterface
|
||||
// find the role for this column:
|
||||
$role = $config['column-roles'][$rowIndex] ?? '_ignore';
|
||||
$doMap = $config['column-do-mapping'][$rowIndex] ?? false;
|
||||
$validConverters = array_keys('csv.import_roles');
|
||||
$validConverters = array_keys(config('csv.import_roles'));
|
||||
|
||||
// throw error when not a valid converter.
|
||||
if (!in_array($role, $validConverters)) {
|
||||
|
@ -361,7 +361,7 @@ class CsvSetup implements SetupInterface
|
||||
$reader = Reader::createFromString($content);
|
||||
$reader->setDelimiter($config['delimiter']);
|
||||
$results = $reader->fetch();
|
||||
$validSpecifics = array_keys('csv.import_specifics');
|
||||
$validSpecifics = array_keys(config('csv.import_specifics'));
|
||||
|
||||
foreach ($results as $rowIndex => $row) {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user