Module: RailsSQLPrettifier::ErrorExt

Defined in:
lib/rails_sql_prettifier.rb

Instance Method Summary collapse

Instance Method Details

#to_sObject


42
43
44
45
46
# File 'lib/rails_sql_prettifier.rb', line 42

def to_s
  # older rails version do not provide sql as a standalone query, instead they
  # deliver joined message
  Niceql.config.prettify_pg_errors ? Niceql::Prettifier.prettify_err(super, try(:sql) ) : super
end