fixing small bugs