arthurnn / memcached

A Ruby interface to the libmemcached C client
Academic Free License v3.0
432 stars 125 forks source link

:namespace key never works #134

Closed evanphx closed 11 years ago

evanphx commented 11 years ago

The code conspires against using :namespace as an alias for :prefix_key.

The code here: https://github.com/evan/memcached/blob/master/lib/memcached/memcached.rb#L110

Makes the code here: https://github.com/evan/memcached/blob/master/lib/memcached/memcached.rb#L153

Into a noop. The :namespace key will never be there on line 153 because it was deleted on line 110.

Suggest that the code on 153 either use opts[:namespace] or explicitly pull it out before pruning @options on 110.

evan commented 11 years ago

I'm inclined to just drop it from memcached.rb since the Rails adaptor handles it correctly; what do you think?

evanphx commented 11 years ago

If you do, blow up when someone uses it. Otherwise they'll use it and it will silently not work.

evan commented 11 years ago

Good point; will do.

evan commented 11 years ago

fixed