Sha256: 84ba219877633e416e739ed9d8d389f90c473b678f6b1ea18a7d2d0a62d4be59
Contents?: true
Size: 340 Bytes
Versions: 36
Compression:
Stored size: 340 Bytes
Contents
class AddForeignKeyConstraintToActiveStorageAttachmentsForBlobId < ActiveRecord::Migration[6.0] def up return if foreign_key_exists?(:active_storage_attachments, column: :blob_id) if table_exists?(:active_storage_blobs) add_foreign_key :active_storage_attachments, :active_storage_blobs, column: :blob_id end end end
Version data entries
36 entries across 36 versions & 4 rubygems