Lib update and some code cleanup