Class: ThinkingSphinx::Middlewares::Geographer::Inner

Inherits:
Object
  • Object
show all
Defined in:
lib/thinking_sphinx/middlewares/geographer.rb

Defined Under Namespace

Classes: GeolocationAttributes

Instance Method Summary (collapse)

Constructor Details

- (Inner) initialize(context)

Returns a new instance of Inner



17
18
19
# File 'lib/thinking_sphinx/middlewares/geographer.rb', line 17

def initialize(context)
  @context = context
end

Instance Method Details

- (Object) call



21
22
23
24
25
26
# File 'lib/thinking_sphinx/middlewares/geographer.rb', line 21

def call
  return unless geo

  context[:sphinxql].values geodist_clause
  context[:panes] << ThinkingSphinx::Panes::DistancePane
end