Perhaps doing this with a little more conventional ruby?

```ruby 
def default_keys_in_lookup_path
  segments = controller_name.split('.')
  
  segments.inject([]) do |defaults, segment|
    defaults.unshift(#blahblahblah)
    segments.delete(segment)
  end
end
```