Fixed bug in settlement module