diff --git a/app/Casts/EncryptedCast.php b/app/Casts/EncryptedCast.php index 1d41b6ce333f..a65e00aab386 100644 --- a/app/Casts/EncryptedCast.php +++ b/app/Casts/EncryptedCast.php @@ -16,8 +16,8 @@ use Illuminate\Contracts\Database\Eloquent\CastsAttributes; class EncryptedCast implements CastsAttributes { public function get($model, string $key, $value, array $attributes) - { - return ! is_null($value) ? decrypt($value) : null; + {nlog($value); + return !$value ? null : decrypt($value); } public function set($model, string $key, $value, array $attributes) diff --git a/database/migrations/2023_05_15_103212_e_invoice_ssl_storage.php b/database/migrations/2023_05_15_103212_e_invoice_ssl_storage.php index f6dab48bd698..2875e0221acb 100644 --- a/database/migrations/2023_05_15_103212_e_invoice_ssl_storage.php +++ b/database/migrations/2023_05_15_103212_e_invoice_ssl_storage.php @@ -15,7 +15,7 @@ return new class extends Migration { Schema::table('companies', function (Illuminate\Database\Schema\Blueprint $table) { $table->text('e_invoice_certificate')->nullable(); - $table->string('e_invoice_certificate_passphrase')->nullable(); + $table->text('e_invoice_certificate_passphrase')->nullable(); }); }