     pull_covers: (market, inverted) ->
         covers = []
         feed_price =  if inverted then 1 / market.feed_price else market.feed_price
+        now  = Date.now()
+        expired = 0
+        margin_called = 0
+        margin_orders = new TradeData()
+        margin_orders.uid = "forced_covers"
+        margin_orders.type = "margin_order"
+        margin_orders.price = if inverted then feed_price * 1.1 else feed_price * (1/1.1)
+        margin_orders.cost = 0.0
+        margin_orders.quantity = 0.0
+        margin_orders.collateral = 0.0
+
+        expired_orders = new TradeData()
+        expired_orders.uid = "expired_covers"
+        expired_orders.type = "margin_order"
+        expired_orders.price = feed_price
+        expired_orders.cost = 0.0
+        expired_orders.quantity = 0.0
+        expired_orders.collateral = 0.0
+
+        margin_calls_dest = if inverted then @bids else @asks
+
         @blockchain_api.market_list_covers(market.asset_base_symbol, market.asset_quantity_symbol, 1000).then (results) =>
             results = if results then [].concat.apply(results) else [] # flattens array of results
-            for r in results
+            for r, i in results
                 continue unless r.type == "cover_order"
                 #r.type = "cover"
                 td = new TradeData()

                td.price_dec = price_string[1]
                td.quantity_filtered = @helper.filter_quantity(td.quantity,market, inverted)
                #td.type = "cover"

                covers.push td
            @helper.update_array {target: @covers, data: covers }
            #console.log "------ pull_covers ------>", @covers
            #@helper.sort_array(@covers, "price", "quantity", !inverted)

    pull_orders: (market, inverted, account_name) ->
        orders = []

                    else
                        short.price = feed_price
                        combined_bids.push short 
            ###
            for cover in @covers
                console.log cover
                if new Date(cover.expiration.timestamp) > now or !(inverted and ask.price < feed_price) or (!inverted and ask.price > feed_price)
                    if not inverted
                        combined_asks.push cover          
                    else
                        combined_bids.push cover
            ###

        for ask in combined_asks
            if inverted                
                if ask.type == "short" and ask.short_price_limit > feed_price
                    ask.price = ask.short_price_limit
        
        for bid in combined_bids
            if not inverted
                if bid.type == "short" and bid.short_price_limit < feed_price
                    bid.price = bid.short_price_limit

        @helper.update_array {
            target: @combined_asks, 
