Firefly III: a personal finances manager
PHP accountingbudgetbudgetingbudgetscash-flowcashflowcredit-carddockerexpensesfinancefinancesfinanciallinuxmoneypaycheckpersonal-financephpphp7
Fix nullable fields.
James Coleabc4f856ce4c
diff --git a/app/Models/ImportJob.php b/app/Models/ImportJob.phpindex d04e126a24..29caecba9d 100644--- a/app/Models/ImportJob.php+++ b/app/Models/ImportJob.php@@ -110,6 +110,9 @@ class ImportJob extends Model*/public function getConfigurationAttribute($value){+ if (is_null($value)) {+ return [];+ }if (strlen($value) == 0) {return [];}diff --git a/database/migrations/2016_06_16_000002_create_main_tables.php b/database/migrations/2016_06_16_000002_create_main_tables.phpindex 1a61e5a579..b14dee042c 100644--- a/database/migrations/2016_06_16_000002_create_main_tables.php+++ b/database/migrations/2016_06_16_000002_create_main_tables.php@@ -290,7 +290,7 @@ class CreateMainTables extends Migration$table->string('key', 12)->unique();$table->string('file_type', 12);$table->string('status', 45);- $table->text('configuration');+ $table->text('configuration')->nullable();$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');});@@ -398,7 +398,7 @@ class CreateMainTables extends Migration$table->softDeletes();$table->integer('user_id', false, true);$table->string('title', 255);- $table->text('description');+ $table->text('description')->nullable();$table->integer('order', false, true)->default(0);$table->boolean('active')->default(1);@@ -416,7 +416,7 @@ class CreateMainTables extends Migration$table->integer('user_id', false, true);$table->integer('rule_group_id', false, true);$table->string('title', 255);- $table->text('description');+ $table->text('description')->nullable();$table->integer('order', false, true)->default(0);$table->boolean('active')->default(1);$table->boolean('stop_processing')->default(0);