From 982704aa2f1980382f75cada432073cb1af04a87 Mon Sep 17 00:00:00 2001 From: Dschonas Date: Wed, 21 Mar 2018 23:04:16 +0100 Subject: [PATCH] Small change --- distribution/service/demandservice.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/distribution/service/demandservice.py b/distribution/service/demandservice.py index 0e69678..cd8760f 100644 --- a/distribution/service/demandservice.py +++ b/distribution/service/demandservice.py @@ -41,11 +41,11 @@ def is_start_hop(message_hop, route_start): def get_start_hop_demand(start_hop): start_hive = hiveservice.get_hive_by(start_hop.start.id) - start_hive.demand -= 1 + start_hive.demand += 1 return start_hive def get_end_hop_demand(route, hop): end_hop = route.hops[len(route.hops)-1] endhop_hive = hiveservice.get_hive_by(end_hop.end.id) - endhop_hive.demand += routeservice.get_route_distance_progress(route, hop) + endhop_hive.demand -= routeservice.get_route_distance_progress(route, hop) return endhop_hive \ No newline at end of file