minor code adjustments