sanitizedKeys method

Map<String, SupabaseForeignKeyConstraint> sanitizedKeys(
  1. List<String> endings
)

Returns a map of sanitized keys for all foreign key relationships of this table.

The key in the map is the result of fk.sanitizedKey(endings), and the value is the SupabaseForeignKeyConstraint itself. The endings list is passed to sanitizedKey to help generate cleaner field names.

Implementation

Map<String, SupabaseForeignKeyConstraint> sanitizedKeys(
  List<String> endings,
) {
  final Map<String, SupabaseForeignKeyConstraint> keys = {};
  for (final fk in foreignKeys) {
    keys[fk.sanitizedKey(endings)] = fk;
  }
  return keys;
}