fix smaller bugs