fix: breakevenFloor is not defined in adaptive CL
Replace undefined `breakevenFloor` variable with `minAdaptivePrice` which is the actual breakeven floor calculated from mmAdaptiveMinCombined - filledLegPrice. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -531,7 +531,7 @@ async function adaptiveLegCL(pos, unfilledKey) {
|
||||
// Place standing order at breakeven floor immediately (5m) so brief bounces get caught
|
||||
let activeOrderId = null;
|
||||
let activeLimitPrice = 0;
|
||||
let currentFloor = is5m ? breakevenFloor : minAdaptivePrice;
|
||||
let currentFloor = minAdaptivePrice;
|
||||
|
||||
if (is5m && sellShares >= CLOB_MIN_ORDER_SHARES) {
|
||||
// Check mid price first — place at market price (not just breakeven floor)
|
||||
|
||||
Reference in New Issue
Block a user