murasaki 0.2.1 → 0.2.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ad4a049570311120ece072730c1b005bc90f5854878fcaf1b5e1a619e26517dc
4
- data.tar.gz: db0f726b3185842c74bf3936e6272de4ae61d80533cf711bd785ea61a20746e1
3
+ metadata.gz: 8a215230abbb509a890da12a276fa95ba32990d1f297cd73e177c765e5f346e3
4
+ data.tar.gz: f983c291f51c8eee403c4174c03091a7c81441b73a5bc81ade080464925140bc
5
5
  SHA512:
6
- metadata.gz: 4c329162006a69c8f321d2fe74cbe16dd7a4cf7368779f19d2ce0b285d1081ffbdd05ef6aea6655890e239535423e136c0701706104124482c8fe18fda50ebab
7
- data.tar.gz: ca8b386203e419ce8931134bb057931d504aac4157c8773da4b2d8c00e0f57ab44a5b9a681db4cd42d3795121d2b35e0314bbc420d327adab4732e6c9376323a
6
+ metadata.gz: 58cb8a6c1271fc8d388dea834aa36f1d2ce0e41193769875996b015aeee4efca8acb52052509d381f3991e2fdbb4d454d57c93cd3dfb38c922c21dab2cd01be0
7
+ data.tar.gz: 3990b258aa7bb692ad62ec64ac867a2532824dab0ab8dd28e49389d28d68193845b6af800c7af24843330cdd91d13c0cd02b190b568a03cb71bd5ab30d7c751e
@@ -103,12 +103,13 @@ module EventLoop
103
103
  # @return [nil] nil
104
104
  def timer_once
105
105
  now_time = Time.now.to_f
106
- @timers.delete_if do |timer|
107
- if timer.start_time < now_time
108
- timer.callback.call
109
- true
110
- end
106
+ callbacks = []
107
+ @timers.reject! do |timer|
108
+ ticked = timer.start_time < now_time
109
+ callbacks << timer.callback if ticked
110
+ ticked
111
111
  end
112
+ callbacks.each { |c| c.call }
112
113
  nil
113
114
  end
114
115
 
@@ -1,5 +1,5 @@
1
1
  # Murasaki Module
2
2
  module Murasaki
3
3
  # Current Version Code
4
- VERSION = '0.2.1'.freeze
4
+ VERSION = '0.2.1.1'.freeze
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: murasaki
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - HeckPsi Lab
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-06-28 00:00:00.000000000 Z
11
+ date: 2018-06-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: nio4r