module Sequel::Plugins::RequireValidSchema::ClassMethods
Private Instance Methods
get_db_schema_array(reload)
click to toggle source
If the schema cannot be determined, the model uses a simple table, require_valid_schema is set, and the database supports schema parsing, raise or warn based on the require_valid_schema setting.
Calls superclass method
# File lib/sequel/plugins/require_valid_schema.rb 50 def get_db_schema_array(reload) 51 schema_array = super 52 53 if !schema_array && simple_table && @require_valid_schema 54 message = "Not able to parse schema for model: #{inspect}, table: #{simple_table}" 55 if @require_valid_schema == :warn 56 warn message 57 else 58 raise Error, message 59 end 60 end 61 62 schema_array 63 end