Module: SwitchConnection::Model::MonkeyPatch
- Defined in:
- lib/switch_connection/model.rb
Instance Method Summary collapse
Instance Method Details
#cache(&block) ⇒ Object
152 153 154 155 156 157 158 |
# File 'lib/switch_connection/model.rb', line 152 def cache(&block) if switch_point_proxy switch_point_proxy.cache(&block) else super end end |
#connection ⇒ Object
142 143 144 145 146 147 148 149 150 |
# File 'lib/switch_connection/model.rb', line 142 def connection if switch_point_proxy connection = switch_point_proxy.connection connection.connection_name = "#{switch_point_name} #{switch_point_proxy.mode}" connection else super end end |
#uncached(&block) ⇒ Object
160 161 162 163 164 165 166 |
# File 'lib/switch_connection/model.rb', line 160 def uncached(&block) if switch_point_proxy switch_point_proxy.uncached(&block) else super end end |