fixed previous commit and tests