isJobInList-1.lua 270 B

12345678910111213141516
  1. --[[
  2. Checks if job is in a given list.
  3. Input:
  4. KEYS[1]
  5. ARGV[1]
  6. Output:
  7. 1 if element found in the list.
  8. ]]
  9. -- Includes
  10. --- @include "includes/checkItemInList"
  11. local items = redis.call("LRANGE", KEYS[1] , 0, -1)
  12. return checkItemInList(items, ARGV[1])