- minor codes cleanup and adjustments