blob: c4659123bb64f431ea5ba669e8c6a3ef859713ed (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
# frozen_string_literal: true
# These classes are used to strip out the ERB configuration
# values so we can evaluate the database.yml without evaluating
# the ERB values.
class DummyERB < ERB # :nodoc:
def make_compiler(trim_mode)
DummyCompiler.new trim_mode
end
end
class DummyCompiler < ERB::Compiler # :nodoc:
def compile_content(stag, out)
case stag
when "<%="
out.push "_erbout << 'dummy_compiler'"
end
end
end
|