We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ba16bf3 commit 2879350Copy full SHA for 2879350
lib/ruby_lsp/ruby_lsp_rails/server.rb
@@ -29,7 +29,7 @@ class Server
29
sig { params(model_name: String).returns(T.nilable(T::Hash[Symbol, T.untyped])) }
30
def resolve_database_info_from_model(model_name)
31
const = ActiveSupport::Inflector.safe_constantize(model_name)
32
- unless const && const < ActiveRecord::Base && !const.abstract_class?
+ unless const && defined?(ActiveRecord) && const < ActiveRecord::Base && !const.abstract_class?
33
return {
34
result: nil,
35
}
0 commit comments