cryptum 0.0.349 → 0.0.350

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: c0c000f85fb12c1e336e3cecf43e6f0c115adb8318509159f7c7da386af96039
4
- data.tar.gz: 582a40ad9d1251912f95560db88a4a91cc83f8815c723470e0161a6c887651bd
3
+ metadata.gz: 07b1c23924235cd1e1e941809b4e6dec5fee5fc75b9f73353a931c22fdc02410
4
+ data.tar.gz: 8a74b80a2366097f40bfc0bf041815864b67ee98ce98f8378cd4a70a29b73abb
5
5
  SHA512:
6
- metadata.gz: 7746a9725be9fec5bf6e27b69695d772c1ebeca5d69c18ff8d924fff34c321938c90547bc6548386db1f1a67dc2fa2298c335f0e7c97dae30ffb394ab6568937
7
- data.tar.gz: 5e4bdb60efca76cc53d4ba81df2dcacd49e5175075e61e36668dd82cc62903156ce0f13174d7e6e370ca906dc8a23bbb601204f6db322d714c4f2aa50a5001dd
6
+ metadata.gz: 92e6b5b3d8bb9c9a30cb5a64ab9316bfcfc245390806d2f01e94d9296dfa547cc126facf7ab7cd77bf95c282c9ec4182d7827b377f15c8e1963ac8b560220339
7
+ data.tar.gz: d413bdd55aba8ad7e40faaf25e5df03ce4eaa6eb7e1e949791ecc9c801a877088040273efbf52e18e197f2b8908924b55be08366717abce51e4f7873930e020f
@@ -103,9 +103,9 @@ module Cryptum
103
103
  fiat_invested_this_order = size.to_f * price.to_f
104
104
 
105
105
  fiat_portfolio = event_history.order_book[:fiat_portfolio]
106
- fiat_avail_for_trade = format('%0.2f', fiat_portfolio.first[:available])
106
+ fiat_avail_to_trade = format('%0.2f', fiat_portfolio.first[:available])
107
107
 
108
- event_history.red_pill = true if fiat_invested_this_order > fiat_avail_for_trade.to_f
108
+ event_history.red_pill = true if fiat_invested_this_order > fiat_avail_to_trade.to_f
109
109
 
110
110
  unless event_history.red_pill
111
111
  event_history = Cryptum::API.submit_limit_order(
@@ -152,7 +152,7 @@ module Cryptum
152
152
  dynamic_time_increment = cast_margin_to_sec * -1
153
153
 
154
154
  # Lets also take balance into play
155
- balance_as_arbitrary_float = fiat_avail_for_trade.to_f / 1_000_000
155
+ balance_as_arbitrary_float = fiat_avail_to_trade.to_f / 1_000_000
156
156
  tbo = dynamic_time_increment - balance_as_arbitrary_float
157
157
 
158
158
  event_history.time_between_orders += tbo
@@ -62,8 +62,7 @@ module Cryptum
62
62
  current_crypto_fiat_value.to_f.fdiv(total_holdings.to_f) * 100
63
63
  )
64
64
 
65
- event_history.red_pill = true if crypto_invested_percent.to_f > autotrade_percent ||
66
- fiat_budget > min_market_funds.to_f
65
+ event_history.red_pill = true if crypto_invested_percent.to_f > autotrade_percent
67
66
 
68
67
  # SAUCE 2
69
68
  # Generating and/or recalculating order plan
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Cryptum
4
- VERSION = '0.0.349'
4
+ VERSION = '0.0.350'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cryptum
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.349
4
+ version: 0.0.350
5
5
  platform: ruby
6
6
  authors:
7
7
  - 0day Inc.