Sha256: 9b342b91ab5cafe90464fbf28c8d3fb84ddbdb5c82ca6fbb98cfe0902397b587
Contents?: true
Size: 441 Bytes
Versions: 18
Compression:
Stored size: 441 Bytes
Contents
# frozen_string_literal: true module Thredded class BaseMigration < (Thredded.rails_gte_51? ? ActiveRecord::Migration[5.1] : ActiveRecord::Migration) def user_id_type Thredded.user_class.columns.find { |c| c.name == Thredded.user_class.primary_key }.sql_type end def column_type(table, column_name) column_name = column_name.to_s columns(table).find { |c| c.name == column_name }.sql_type end end end
Version data entries
18 entries across 18 versions & 2 rubygems