debounce 0.1.2 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 96c6a78a36d7b65bf4320546f4c26821c413f66a
4
- data.tar.gz: 1f68e7cfced478fed799254ee86443890d959d47
3
+ metadata.gz: 66ca25c71bd0aa2696c3bb05e98b3a1b6e597dd4
4
+ data.tar.gz: 99533c74ef861d147d915a2ace88de44ed20c26b
5
5
  SHA512:
6
- metadata.gz: 32af41082f5a9f7c64225e921cac58795e08eb5aa7d7e13c38967485bb1a9bc50a1697a27cfad1cad2e99b4a1a122c11047c769d5007fb4e58e9c28a684a7885
7
- data.tar.gz: 1eb8062340b7c6be48fe0b90782b9cb7ce9c0e5846f2797869b929f465b0b1b8e8e911891ef9658bfd34891d7615cc73197c2ca6612bf5c8022f3d8be2343857
6
+ metadata.gz: 3e8fe19eddf05c77149cfb6d07cf075557f30fb612e83771f2f475ba1bf241e7b11d3dd29c75c205d819c2842c499121ef96bb6a75791c5bf83fdcbdc0485aa4
7
+ data.tar.gz: 788f0f6ab79d484256839e3b4826913b80a22bf621234a8ef39125683022d653f32d0d421b8e68c407bd40c12f720151c598f8528ec2255fd1bb27c0673b546c
@@ -1,4 +1,7 @@
1
1
  language: ruby
2
2
  rvm:
3
3
  - 2.1.5
4
+ - 2.2.2
4
5
  before_install: gem install bundler -v 1.10.3
6
+ services:
7
+ - redis-server
data/README.md CHANGED
@@ -1,3 +1,5 @@
1
+ [![Build Status](https://travis-ci.org/bettyblocks/debounce.svg)](https://travis-ci.org/bettyblocks/debounce)
2
+
1
3
  # Debounce
2
4
 
3
5
  Creates a debounced function that delays invoking func until after wait milliseconds have elapsed since the last time the debounced function was invoked.
@@ -23,7 +23,7 @@ module Debounce
23
23
  semaphore1.lock(timeout) do
24
24
  start = Time.now
25
25
  semaphore2 = Redis::Semaphore.new("#{lock_key}-2", resources: 1, stale_client_timeout: stale_client_timeout, redis: redis.dup)
26
- semaphore2.lock do
26
+ semaphore2.lock(timeout) do
27
27
  yield
28
28
  end
29
29
  duration = Time.now - start
@@ -1,3 +1,3 @@
1
1
  module Debounce
2
- VERSION = "0.1.2"
2
+ VERSION = "0.2.0"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: debounce
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stephan Kaag