fixed bug again and test working