Skip to content

Instantly share code, notes, and snippets.

@Porta
Created June 18, 2015 14:24
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Porta/71351f0343daf76e98e6 to your computer and use it in GitHub Desktop.
Save Porta/71351f0343daf76e98e6 to your computer and use it in GitHub Desktop.
local function search(words)
local cached_key, cached = temp_dest_key(words)
if cached == false then
redis.call('BITOP', 'AND', cached_key, unpack( namespace_keys(words) ) )
cached = redis.call('GET', cached_key)
end
return cached
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment