From 1e29294230ae6d4927a5f90c4add73cda677e88b Mon Sep 17 00:00:00 2001 From: Eduardo <279828+sezaru@users.noreply.github.com> Date: Tue, 31 Oct 2023 17:38:08 -0300 Subject: [PATCH] fix: Fix missing nulls_distinct field in old snapshots Old snapshots can come without the `nulls_distinct` field, because of that we return null if the key doesn't exists --- lib/migration_generator/operation.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/migration_generator/operation.ex b/lib/migration_generator/operation.ex index edec453c..1eb0f03c 100644 --- a/lib/migration_generator/operation.ex +++ b/lib/migration_generator/operation.ex @@ -944,7 +944,7 @@ defmodule AshPostgres.MigrationGenerator.Operation do option(:name, index.name), option(:unique, index.unique), option(:concurrently, index.concurrently), - non_nullable_option(:nulls_distinct, index.nulls_distinct), + non_nullable_option(:nulls_distinct, index[:nulls_distinct]), option(:using, index.using), option(:prefix, index.prefix), option(:where, index.where),