clean up code
merged latest pull