Small changes for refactoring and moving to new version
More asserts