fixes after running tests and some failed